Skip to content

Concurrency

Concurrent operations with cancellation before an error reaches the caller.

gather_with_cancellation(*operations) async

Return ordered results, or cancel and await sibling tasks before raising.

Parameters:

Name Type Description Default
operations Coroutine[Any, Any, T]

Independent operations in result order.

()

Returns:

Type Description
list[T]

list[T]: One result per operation.