STINNER Victor added the comment:

The CPython test suite uses a counter on memory allocations. Please add an unit 
test which triggers the memory leak, but you don't need many iterations. One 
iteartion should be enough to be catched by the unit test. Try: ./python -m 
test -R 3:3 test_dict.

The memory allocation counter:
https://docs.python.org/dev/library/sys.html#sys.getallocatedblocks

Note: The tracemalloc module can also be used to track memory leak, but it's 
harder to use it to write unit tests because Python uses a lot of internal 
caches and tracemalloc really tracks every single bytes.

----------

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

Reply via email to