Optimize the generation of "app_dir" #656
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Issue
Reproduction
Use the

app2execommand to package it as an application and execute it. The "pyxapp" file will be decompressed twice in the temporary directory of the systemUse the

app2execommand to package it as an application and execute it. Whenever thepyxel.reset()method is triggered, the "pyxapp" file will be repeatedly decompressed in the system's temporary directoryImpact
This will lead to performance degradation during the application's runtime and some unknown issues
Optimization
In the startup logic of the application, set an environment variable to record the decompression path of the "pyxapp" file. When the startup logic is triggered again, prioritize obtaining the decompression path from this environment variable to avoid further decompression operations