Amaury Forgeot d'Arc <[EMAIL PROTECTED]> added the comment: Setting builtins._=None is not enough.
My example is very simple, but the crash I had initially was during the deletion of sys.last_tb: the C() object may be stored anywhere. I agree that the test in PyModule_Create2 is too strong: the import machinery is still functional at this point. It could be replaced by something that becomes true on _PyImport_Init(), and false on _PyImport_Fini(). ---------- nosy: +loewis _______________________________________ Python tracker <[EMAIL PROTECTED]> <http://bugs.python.org/issue4236> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: http://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com