~/talk

Notes, Groups and Stars: exceptional new features of Python 3.11!

Talkat PyCon US 2025 · 2025-05-16..05-18· [python]
slides:none on file

Python 3.11 actually adds concrete error‑handling tools: add_note() annotations, hierarchical ExceptionGroup objects, and the new except syntax for selective handling. The talk demos tracebacks that pinpoint the failing subexpression, shows pytest fixture teardown and async task groups producing groups, and explains subgroup/split helpers and a proposed group.leaf_exceptions plus a context manager to preserve concise tracebacks. These features exist and help, but extracting single leaves without losing context remains fiddly and needs helper APIs/backports.

AI-written summary · about

  1. 0:00Exception handling in Python
  2. 1:08Exceptions vs error returns
  3. 3:12Automatic exception propagation
  4. 4:14Python tracebacks
  5. 5:16Exception chaining and causes
  6. 7:02Modifying tracebacks
  7. 8:27Adding notes to exceptions
  8. 9:52Exception groups
  9. 13:28Except star syntax
  10. 15:35Handling exception groups
  11. 17:26Flattening exception groups
  12. 19:10Destructuring exception groups
  13. 19:54Q&A
~/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.