~/talk

Demystifying AsyncIO: Building Your Own Event Loop in Python

Talkat PyCon US 2024 · 2024-05-15..05-23· [python]
slides:none on file

Builds an event loop from scratch in Python and actually runs a FastAPI HTTP server on it, printing a Hello World response; measures show the homemade loop is 97% slower than the CPython default while replacing the loop with uvloop 2–4x faster narrows the gap. Uses selectors, Futures, Tasks, scheduling queues, and simple benchmarks via the cpit project to compare performance and demonstrate what parts are costly and which optimizations matter.

AI-written summary · about

  1. 0:00Introduction
  2. 5:19Scheduling callbacks
  3. 8:50Futures
  4. 10:38Aseno Helpers
  5. 12:39AsyncIO
  6. 15:28Syntax
  7. 18:49Performance
  8. 23:24Questions
~/search
type to search 6,249 conferences, 138,987 speakers and 185,172 talks
~/help
cmdctrl k
search every conference, speaker and series
/
focus the filter search
h
home
c
conferences
s
speakers
e
series
t
light / dark — the status bar button does the same
?
this help
esc
close this, then clear every filter — or just the search, while you are typing in it

Ignored while you are typing. Pages without a filter rail have no search to focus.