[issue27535] Memory leaks when opening tons of files

Александр Карпинский report at bugs.python.org
Sun Jul 17 01:46:24 EDT 2016


Александр Карпинский added the comment:

@serhiy.storchaka

Any filters not solves the problem because warnings module SAVES EVERY WARNING MESSAGE for further duplication checks.

Yes, the file name is helpful for determining the source of the POSSIBLE leak. While file name in error message IS SOURCE OF THE LEAK. When you aware about not closed files, you can log file names. You have a way to do that. But if you want to ignore the warning, the memory will leak. Not because of not closed files, but because of warning itself.

I do want to close files in my script, but in Pillow, it is not so easy due to backward compatibility.

----------

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


More information about the Python-bugs-list mailing list