Skip to content

Does pyinstaller do dead code elimination/code optimizaiton? #8948

Discussion options

You must be logged in to vote

Not really.

The import analysis (based on modulegraph) might help us avoid collecting unused modules of a package, although in practice, due to indirect imports (e.g., programmatic imports with dynamically constructed module names) we often need to resort to collecting all modules from a package just to have things work. But there's no pruning of let's say unused functions or classes within the modules, etc. (Plus the contents of binary extensions and shared libraries cannot be split/pruned anyway).

or maybe is willing to add in the roadmap?

As far as I'm concerned, the answer is no. Just keeping things running around here takes enough effort.

From my perspective, it would make more sen…

Replies: 1 comment 2 replies

Comment options

You must be logged in to vote
2 replies
@baseplate-admin
Comment options

@bwoodsend
Comment options

Answer selected by baseplate-admin
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
3 participants