[pypy-dev] Memory leaking with iterator.close() in PyPy3
hubo
hubo at jiedaibao.com
Thu Jun 28 01:06:31 EDT 2018
In PyPy3, when an iterator is closed with "close()" method, the iterator leaks and cannot be collected.
Execute the following script in PyPy3, the memory usage is increasing very fast, and gc.collect() cannot collect the memory
def test():
yield 1
while True:
t = test()
t.close()
The tested version:
Python 3.5.3 (fdd60ed87e94, Apr 24 2018, 06:10:04)
[PyPy 6.0.0 with GCC 6.2.0 20160901]
This is not reproduced in CPython 3.5 and PyPy2.
2018-06-28
hubo
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/pypy-dev/attachments/20180628/46f82b2d/attachment.html>
More information about the pypy-dev
mailing list