Concurrency
Multitasking and asynchronous execution models. Understand thread synchronization, non-blocking coroutines with asyncio Task Groups, and isolated subinterpreters.
Chapter Lessons
Thread
Threaded programming is used by developers to improve the performance of an application. This module shows how a multiplication operation with some delay can be parallelized using `ThreadPoolExecutor`.
Process
Process-based parallelism via multiprocessing and concurrent.futures.
Async
Python 3.11Concurrent programming with asyncio, introduced in Python 3.4, provides an event loop for handling asynchronous operations. This module demonstrates basic asyncio patterns including coroutines, tasks, concurrent execution with gather, and task cancellation. It uses the context of a scheduler which runs fire-and-forget operations for starting jobs, assuming that job startup has some intrinsic delay.
Subinterpreters
Python 3.14Multi-interpreter support via concurrent.interpreters in Python 3.14 (PEP 734).