New submission from Peter Santoro: Now that zipfile.ZipFile supports the context manager protocol, shouldn't shutil._make_zipfile make use of it to avoid the possibility of the archive file not being closed properly if an exception occurs? It should be noted that shutil._unpack_zipfile does use try/finally to ensure that files are closed.
---------- components: Library (Lib) files: shutil.diff keywords: patch messages: 207132 nosy: pe...@psantoro.net priority: normal severity: normal status: open title: shutil._make_zipfile possible resource leak type: behavior versions: Python 3.3, Python 3.4, Python 3.5 Added file: http://bugs.python.org/file33291/shutil.diff _______________________________________ Python tracker <rep...@bugs.python.org> <http://bugs.python.org/issue20102> _______________________________________ _______________________________________________ Python-bugs-list mailing list Unsubscribe: https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com