[issue38006] Crash in remove() weak reference callback of weakref.WeakValueDictionary at Python exit

Tim Peters report at bugs.python.org
Mon Sep 30 12:42:38 EDT 2019


Tim Peters <tim at python.org> added the comment:

Neil, how about this alternative:  leave the weakref implementation alone.  If we find a trash weakref, simply clear it instead.  That would prevent callbacks too, & would also prevent the weakref from being used to retrieve its possibly-trash-too referent.

----------

_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue38006>
_______________________________________


More information about the Python-bugs-list mailing list