Run
The jobs of one run, each as it finishes.
Usage
Run(
jobs,
progress,
)Iteration yields each job once, so all, one and partitions return only the jobs it has not yet yielded. After the last job, it raises IncompleteRunError if a payload ended with no done or faulted job or an upload failed, and raises it again on each later call.
Attributes
| Name | Description |
|---|---|
| progress | The number of the run’s payloads in each state, now. |
progress
The number of the run’s payloads in each state, now.
progress: Progress
Methods
| Name | Description |
|---|---|
| __iter__() | Yield each job as it finishes. |
| all() | Wait for every job, and return them in the order they finished. |
| one() | Wait for the run’s only job, and return it. |
| partitions() |
Yield the jobs in lists of size as they finish, with a shorter last list.
|
__iter__()
Yield each job as it finishes.
Usage
__iter__()all()
Wait for every job, and return them in the order they finished.
Usage
all()Raises
IncompleteRunError-
If a payload ended with no done or faulted job or an upload failed, with the jobs collected so far in its
jobs.
one()
Wait for the run’s only job, and return it.
Usage
one()Raises
ValueError- If the run holds more or fewer than one job.
partitions()
Yield the jobs in lists of size as they finish, with a shorter last list.
Usage
partitions(size)When the run raises, the partial list comes first, so a bulk write keeps every job.