Author vstinner
Recipients petr.viktorin, shihai1991, vstinner
Date 2020-11-03.12:33:55
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <>
There is a leak (I just marked bpo-42250 as duplicate of this issue):

test_ast leaked [23640, 23636, 23640] references, sum=70916
test_ast leaked [7932, 7930, 7932] memory blocks, sum=23794
1 test failed again:

test_subinterpreter() test leaks.

There are two problems:

* _PyAST_Fini() is only called in the main interpreter, I forgot to remove the "if _Py_IsMainInterpreter()"
* _PyAST_Fini() is called after the last GC collection, whereas AST_type contains a reference to itself (as any Python type) in its tp_mro member. A GC collection is required to destroy the type. _PyAST_Fini() must be called before the last GC collection.
Date User Action Args
2020-11-03 12:33:55vstinnersetrecipients: + vstinner, petr.viktorin, shihai1991
2020-11-03 12:33:55vstinnersetmessageid: <>
2020-11-03 12:33:55vstinnerlinkissue41796 messages
2020-11-03 12:33:55vstinnercreate