Async
run_concurrent_tasks
async
¶
Run multiple tasks concurrently with a limit on concurrent execution.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
tasks
|
list[Callable[P, T]]
|
List of async callables to execute |
required |
max_concurrent
|
int
|
Maximum number of tasks to run concurrently |
max_concurrent_tasks
|
run_sync_in_worker_thread
async
¶
Runs a sync function in a new worker thread so that the main thread's event loop is not blocked.