A living example of superfunctions
Project description
supertime: a living example of the superfunctions
The transfunctions library introduces a new type of function: superfunction. They can behave both as regular and asynchronous functions, depending on the context, that is, on how the user uses them. This micro-library demonstrates the smallest example of this concept that I could come up with.
Install it:
pip install supertime
And try:
from asyncio import run
from supertime import supersleep
supersleep(5) # sleeps 5 sec.
run(supersleep(5)) # sleeps 5 sec., but ASYNCHRONOUSLY.
As you can see, the superfunction can automatically adjust to how the calling code uses it.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file supertime-0.0.2.tar.gz.
File metadata
- Download URL: supertime-0.0.2.tar.gz
- Upload date:
- Size: 3.5 kB
- Tags: Source
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
ee244b73e1e9103e8335c1a7d2d0e96456396f20189559ead2c3b4e67fb2af3e
|
|
| MD5 |
b121110243dd7c309263912054bf5ff9
|
|
| BLAKE2b-256 |
27a1aa3ace0c750a1a779b4f4f13a9354b9b6025c168bd1f9d57dc206a9f3289
|
Provenance
The following attestation bundles were made for supertime-0.0.2.tar.gz:
Publisher:
release.yml on pomponchik/supertime
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
supertime-0.0.2.tar.gz -
Subject digest:
ee244b73e1e9103e8335c1a7d2d0e96456396f20189559ead2c3b4e67fb2af3e - Sigstore transparency entry: 654306077
- Sigstore integration time:
-
Permalink:
pomponchik/supertime@3e6567ab17c5f8cb7c0a7186a8554966eeeff9b0 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/pomponchik
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3e6567ab17c5f8cb7c0a7186a8554966eeeff9b0 -
Trigger Event:
push
-
Statement type:
File details
Details for the file supertime-0.0.2-py3-none-any.whl.
File metadata
- Download URL: supertime-0.0.2-py3-none-any.whl
- Upload date:
- Size: 3.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? Yes
- Uploaded via: twine/6.1.0 CPython/3.13.7
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
00a5fa2c48a0d78b0aabaf32ed171278555a9ef806c437339998909e1221cd5c
|
|
| MD5 |
182a66d5931e78ff7f347d12c9e30301
|
|
| BLAKE2b-256 |
5d159d2d0e575b83f484bf08177766af6cf77bea8ce3112c8f8571267a925bf7
|
Provenance
The following attestation bundles were made for supertime-0.0.2-py3-none-any.whl:
Publisher:
release.yml on pomponchik/supertime
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
supertime-0.0.2-py3-none-any.whl -
Subject digest:
00a5fa2c48a0d78b0aabaf32ed171278555a9ef806c437339998909e1221cd5c - Sigstore transparency entry: 654306089
- Sigstore integration time:
-
Permalink:
pomponchik/supertime@3e6567ab17c5f8cb7c0a7186a8554966eeeff9b0 -
Branch / Tag:
refs/heads/main - Owner: https://github.com/pomponchik
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
release.yml@3e6567ab17c5f8cb7c0a7186a8554966eeeff9b0 -
Trigger Event:
push
-
Statement type: