This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author eighthave
Recipients eighthave
Date 2021-03-18.21:25:38
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1616102738.26.0.451702371832.issue43547@roundup.psfhosted.org>
In-reply-to
Content
It is now standard for Java JARs and Android APKs (both ZIP files) to zero out lots of the fields in the ZIP header.  For example:

* each file entry has the date set to zero
* the create_system is always set to zero on all platforms

zipfile currently cannot create such ZIPs because of two small restrictions that it introduced:

* must use a tuple of 6 values to set the date
* forced create_system value based on sys.platform == 'win32'
* maybe other fields?

I lump these together because it might make sense to handle this with a single argument, something like zero_header=True.  The use case is for working with ZIP, JAR, APK, AAR files for reproducible builds.  The whole build system for F-Droid is built in Python.  We need to be able to copy the JAR/APK signatures in order to reproduce signed builds using only the source code and the signature files themselves.  Right now, that's not possible because building a ZIP with Python's zipfile cannot zero out the ZIP header like other tools can, including Java.
History
Date User Action Args
2021-03-18 21:25:38eighthavesetrecipients: + eighthave
2021-03-18 21:25:38eighthavesetmessageid: <1616102738.26.0.451702371832.issue43547@roundup.psfhosted.org>
2021-03-18 21:25:38eighthavelinkissue43547 messages
2021-03-18 21:25:38eighthavecreate