[issue19021] AttributeError in Popen.__del__

Richard Oudkerk report at bugs.python.org
Wed Sep 25 18:06:38 CEST 2013


Richard Oudkerk added the comment:

The clearing of modules at shutdown has been substantially changed in 3.4.  Now a best effort is made to let the module go away purely by gc.  Those modules which survive get purged in random order.

In 3.3 all modules were purged, but builtins was special cased to be purged last.  (See Python/import.c:PyImport_Cleanup().)

I would favour setting a flag before the purging stage which prevents __del__ methods (and weakrefs?) from running.

----------
nosy: +pitrou, sbt

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue19021>
_______________________________________


More information about the Python-bugs-list mailing list