zipapp should not include temporary files?

Irmen de Jong irmen.NOSPAM at xs4all.nl
Wed Jul 26 13:36:49 EDT 2017


Hi,

when creating an executable zip file using the zipapp module, it's a little sad to see
that no effort is done to filter out obvious temporary files: the resulting zipfile
contains any *.pyc/pyo files and other things such as .git, .tox, .tmp folders.

The documentation says "zip is created from the contents of the directory" so strictly
speaking it's not wrong that it is doing this. However I think it is inconvenient,
because we either have to clean out the directory manually first before zipping it, or
afterwards, remove stuff from the resulting zipfile.

What do you think? Should the zipapp module perhaps be improved to automatically skip
obvious temporary files or perhaps allow to provide a filter function?


Irmen



More information about the Python-list mailing list