[docs] [issue17468] Generator memory leak

Benjamin Peterson report at bugs.python.org
Sat Apr 20 15:19:43 CEST 2013


Benjamin Peterson added the comment:

In a sense, doing something like "with self.lock" in a generator is already a leak. Even if there wasn't a cycle, collection could be arbitrarily delayed (in partincular on non-CPython VMs). I wonder if making generators context managers which call close() on exit would help.

----------

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


More information about the docs mailing list