STINNER Victor <victor.stin...@gmail.com> added the comment:

(I prefer to not split the discussion on this issue and my 2 PR, I prefer to 
only discuss the design in this issue.)

https://github.com/python/cpython/pull/3927#pullrequestreview-67963845

Serhiy:
> Using the requires_type_collecting decorator LGTM. But I don't sure about 
> adding PYTHONSHOWALLOCCOUNT. This looks like a new feature to me.
> What if split this PR on two parts? The one fixes issues related to immortal 
> types, the other is about additional output.

Both changes are connected. If you only want to fix tests, that's the purpose 
of my much longer PR 3910.

"This looks like a new feature to me."

My PR changes the default behaviour, but COUNT_ALLOCS is not enabled by 
default, not even by the debug mode. You have to explicitely enable it. I 
expect that developers who use this option are able to track the Python 2.7 
changelog and "discover" the newly added environment variable by themself. 
Moreover, defining PYTHONSHOWALLOCCOUNT=1 is "backward compatible" with Python 
< 2.7.15 and Python 3, since unknown environment variables are just ignored.

----------

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

Reply via email to