[issue28653] refleak in functools.lru_cache

Ivan Levkivskyi report at bugs.python.org
Wed Nov 9 18:51:37 EST 2016


Ivan Levkivskyi added the comment:

FWIW, if I comment out this code

try:
    from _functools import _lru_cache_wrapper
except ImportError:
    pass

in functools.py to use the pure Python version, then I get much larger numbers:

$ ./python -m test -R : test_typing
Run tests sequentially
0:00:00 [1/1] test_typing
beginning 9 repetitions
123456789
.........
test_typing leaked [25003, 25003, 25003, 25003] references, sum=100012
test_typing leaked [9350, 9352, 9352, 9352] memory blocks, sum=37406
test_typing failed

----------
nosy: +levkivskyi

_______________________________________
Python tracker <report at bugs.python.org>
<http://bugs.python.org/issue28653>
_______________________________________


More information about the Python-bugs-list mailing list