asyncio.TaskGroup
keeps references to errors after raising ExceptionGroup
#98543
Labels
3.11
only security fixes
3.12
bugs and security fixes
topic-asyncio
type-bug
An unexpected behavior, bug, or error
asyncio.TaskGroup
keeps references to errors after raising ExceptionGroup. This is because it keeps a ref to list of errors inerrors
local and since this local is kept alive by frame via traceback, this causes ref cycles. The correct fix is to useself._errors
directly and then assignNone
to it in finally.cpython/Lib/asyncio/taskgroups.py
Lines 127 to 135 in 8d57423
The text was updated successfully, but these errors were encountered: