Python asyncio Reference: gather, TaskGroup, to_thread, aiohttp, Queue with Backpressure
asyncio patterns that come up constantly in real async Python code.
gather vs TaskGroup — which to use
import asyncio
# asyncio.gather — concurrent tasks, results in order
results = await asyncio.gather(
fetch_user(1),
fetch_posts(1),
fe...
releaserun.hashnode.dev2 min read