# collect_all()

Wait until every task is terminal.

Usage

[Source](https://github.com/shikokuchuo/pymizu/blob/main/python/pymizu/__init__.py#L1063-L1092)

``` python
collect_all(
    tasks,
    timeout=None,
)
```

## Parameters

`tasks: _Iterable[Task]`  
The [`Task`](../reference/Task.md#pymizu.Task) handles to wait on.

`timeout: float | None = None`  
Seconds to wait; None waits indefinitely.

## Returns

`All values in input order. On the first failure by position, raises`  
with an `index` attribute (0-based). Only the reported handle is consumed, and every other handle, including the results ahead of it, stays collectible. A result that fails to read raises with `index` and a `values` attribute carrying the consumed prefix. The `TIMEOUT` sentinel consumes nothing.

## Raises

`ConcurrentUseError`  
Another wait-half verb (a blocking collect, [stop()](../reference/pymizu.Pool.stop.md)) is in flight on this handle from a second thread: the waiting half is confined to one thread (the class docstring).
