Dagather
dagather (directed acyclic gather) is a new way to plan out and schedule asynchronous tasks. The tasks are organized, with each task specifying the tasks that come before it. The tasks are then run in topological order, ensuring that each operation will start as soon as it is able to without waiting for routines it does not need.
from asyncio import sleep
from dagather import Dagather
foo = Dagather()
@foo.register
# add a new task to the task list
async def a():
await sleep(1)
return 12
@foo.register
async def b(a):
# we now specify that a is a requirement for this task,
# meaning that b will not be called until a has finished.
# during runtime, a's value will be the return value of the
# a task
assert a == 12
await sleep(2)
@foo.register
async def c(a):
await sleep(1)
return 'testing'
@foo.register
async def d():
await sleep(1)
@foo.register
async def e(d, c):
await sleep(1)
result = await foo()
# when foo is called, it runs each of its registered tasks
# as soon as all its dependencies are finished.
# once all the tasks are finished, it will return a dict
# mapping each task to its return value.
assert result == {
a: 12,
b: None,
c: 'testing',
d: None,
e: None
}
Metadata
Release files for dagather 0.1.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| dagather-0.1.0.tar.gz | 7.8 kB | Without provenance | Details for dagather-0.1.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| dagather-0.1.0-py3-none-any.whl | Python 3 | none | any | Details for dagather-0.1.0-py3-none-any.whl |
Total release size: 17.0 kB
Release files / dagather-0.1.0.tar.gz
| Download URL | dagather-0.1.0.tar.gz |
|---|---|
| Size | 7.8 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9b986a9b35f24887abdbd572b664107a5f778c70e46c7f23019196b3a50397f4
|
|
BLAKE2b-256 checksum How to use checksums |
c7eef62a9e6ff8056c3fe8282c6ca9b2cc08a03f536ef9760460a9d9e07166b4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.8.7 Linux/5.4.0-1036-azure
|
Release files / dagather-0.1.0-py3-none-any.whl
| Download URL | dagather-0.1.0-py3-none-any.whl |
|---|---|
| Size | 9.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
4327820bec2286108be4caa9e6fa44404ed97fff55ca6281d5219287fab1b015
|
|
BLAKE2b-256 checksum How to use checksums |
ea3b09d0a7514791c6851ee8181da353ec72fae23b2be2f366865df8c592d8bc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
poetry/1.1.4 CPython/3.8.7 Linux/5.4.0-1036-azure
|
Security for dagather 0.1.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.