added 4 commits
March 19, 2026 12:03We make the PY_UNWIND monitoring event available as a code-local event to allow trapping on function exit events when an exception bubbles up. This complements the PY_RETURN event by allowing to catch any function exit event.
Open
P403n1x87 marked this pull request as ready for review
March 23, 2026 11:36Closed
P403n1x87 deleted the gh-142186-pep-669-all-local-events branch
April 22, 2026 08:57Closed
Merged
scoder added a commit that referenced this pull request
Apr 25, 2026ljfp pushed a commit to ljfp/cpython that referenced this pull request
Apr 25, 2026…isableable (pythonGH-146182) * Make the `PY_UNWIND` monitoring event available as a code-local event to allow trapping on function exit events when an exception bubbles up. This complements the PY_RETURN event by allowing to catch any function exit event. * Allow `PY_UNWIND` to be `DISABLE`d; disabling it disables the event for the whole code object. * Do the above for `PY_THROW`, `RAISE`, `EXCEPTION_HANDLED`, and `RERAISE` events.