Understanding Asyncio Internals

By Jane Developer

The event loop is the core of asyncio. It manages I/O events and schedules coroutines to run.

The Event Loop

asyncio uses a single-threaded event loop to run coroutines.

Tasks and Futures

A Task wraps a coroutine and schedules it on the event loop.