I have a python zipapp (specifically, of pdm). When running from the filesystem, it takes around 0.300s
just to show the help page. However, with my zipapp, its 1s
. The zipapp is around 25 MB (it includes all of the dependencies).
Getting a file in an uncompressed zip should be almost as fast as reading it since there's an index to tell you where to go in the file to get there.
EDIT: I was able to reengineer my code to be able to be profiled with cProfile. It seems that the extra 0.6 seconds is spent with compile
, but I'm not sure for what.