STINNER Victor <vstin...@python.org> added the comment:

Thanks to recent enhancements, epecially in bpo-46417, the last memory blocks 
are now released at Python exit! The initial issue has been fixed!!! This bug 
was 15 years old! Current main branch:

$ ./python -I -X showrefcount -c pass
[-5 refs, 0 blocks]

"0 blocks" means that Python no longer leaks memory at exit. You can use 
Valgrind to check it ;-)

The negative reference count is being discussed in bpo-46449.

I close this issue since it has an insane history: too many pull requests, 
changes, etc.

While the work is not 100% done (we need to convert remaining static types to 
heap types, and convert extensions to multi-phase init), I prefer to address 
remaining issues in (existing or new) separated issues. See for example the 
bpo-40077: "Convert static types to heap types: use PyType_FromSpec()".

I would like to thank everybody who helped to fix this issue! It's hard to list 
all names since this issue is a meta issues made of many sub-issues which also 
have sub-issues. Authors of PEP 573 and PEP 630 also helped fixing this issue!

----------
resolution:  -> fixed
stage: patch review -> resolved
status: open -> closed
versions: +Python 3.11 -Python 3.10

_______________________________________
Python tracker <rep...@bugs.python.org>
<https://bugs.python.org/issue1635741>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe: 
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com

Reply via email to