[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-09-23 Thread Roundup Robot
Roundup Robot added the comment: New changeset 8a010ca89094 by Serhiy Storchaka in branch '2.7': Issue #21866: ZipFile.close() no longer writes ZIP64 central directory https://hg.python.org/cpython/rev/8a010ca89094 New changeset 8f25d118ce38 by Serhiy Storchaka in branch '3.4': Issue #21866:

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-09-23 Thread Serhiy Storchaka
Changes by Serhiy Storchaka storch...@gmail.com: -- resolution: - fixed stage: patch review - resolved status: open - closed ___ Python tracker rep...@bugs.python.org http://bugs.python.org/issue21866 ___

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-09-05 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Thank you Benjamin for explanation. Here is a patch which adds all three required checks in the close() method and adds a check for files count in write methods. Implementing other checks in write methods is too laborious. As far as test_zipfile64 is

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-07-07 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: An offset is checked in write() and writestr() methods and an exception is raised if an offset is = 2 GiB and ZIP64 extension is not allowed. I don't see a possibility for a bug. -- status: open - pending ___

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-07-07 Thread Benjamin Gilbert
Benjamin Gilbert added the comment: Here are the cases where close() will generate a ZIP64 archive and an exception will never be raised: 1. There are more than 65535 files in the archive. 2. The start of the central directory is at 2 GB. 3. The central directory size is 2 GB. #1 could be

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-06-25 Thread Serhiy Storchaka
Serhiy Storchaka added the comment: Do you want to provide a patch? -- assignee: - serhiy.storchaka nosy: +serhiy.storchaka stage: - needs patch versions: -Python 3.1, Python 3.2, Python 3.3 ___ Python tracker rep...@bugs.python.org

[issue21866] zipfile.ZipFile.close() doesn't respect allowZip64

2014-06-24 Thread Benjamin Gilbert
New submission from Benjamin Gilbert: The ZipFile documentation says: If allowZip64 is True (the default) zipfile will create ZIP files that use the ZIP64 extensions when the zipfile is larger than 2 GiB. If it is false zipfile will raise an exception when the ZIP file would require ZIP64