~/talk

Inside web framework: intro to the ASGI spec, middleware and apps

Talkat PyCon US 2023 · 2023-04-19..04-27· [python, web-platform]
links:none on file
slides:none on file

Covers the ASGI specification for asynchronous web apps and how it powers frameworks like FastAPI and Django; explains ASGI message flow and lifecycle. Shows how to implement a minimal ASGI app in plain Python, how to write custom ASGI middleware for tasks like authentication or request-body handling, and how to serve ASGI apps programmatically using Uvicorn and manage the event loop.

AI-written summary · about

  1. 0:00Start
  2. 3:15What is the ASGI spec?
  3. 4:05ASGI Scope
  4. 5:07ASGI Receive
  5. 6:17Objects as applications
  6. 6:50Server Stub
  7. 9:04Streaming echo app
  8. 10:23Motivation
  9. 13:57Starlette & middleware
  10. 15:03Read/modify scope
  11. 16:30Wrap request body
  12. 17:40Wrap response
  13. 19:00Storing state in middleware
  14. 19:39Request scope
  15. 20:07Sharing state- per lifespan
  16. 21:48On the middleware itself
  17. 23:00Helper functions
~/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.