[DRAFT] Installer python rewrite#2292
Closed
ebr wants to merge 18 commits into
Closed
Conversation
dfa4b77 to
ee04852
Compare
There is a race condition affecting the 'tempfile' module on Windows. A PermissionsError is raised when cleaning up the temp dir Python3.10 introduced a flag to suppress this error. Windows + Python3.9 users will receive an unpleasant stack trace for now
This allows reliable distribution of the initial 'configs' directory with the Python package, and enables the configuration script to be running from anywhere, as long as the virtual environment is available on the sys.path
the 'setup.py install' method is deprecated in favour of a build-system independent format: https://peps.python.org/pep-0517/ this is needed to install dependencies that don't have a pyproject.toml file (only setup.py) in a forward-compatible way
if the config directory is missing, initialize it using the standard process of copying it over, instead of failing to create the config file this can happen if the user is re-running the config script in a directory which already has the init file, but no configs dir
…h experience on Linux/Mac - install.sh is now a thin wrapper around the pythonized install script - install.bat not done yet - to follow - user messaging is tailored to the current platform (paste shortcuts, file paths, etc) - emit invoke.sh/invoke.bat scripts to the runtime dir - improve launch scripts (add help option, etc) - only emit the platform-specific scripts
Contributor
Author
|
superceded by #2338 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
WIP PR for the new pure python installer + robust path handling module. PR only to help diff the changes against
dev/diffusers.Not yet ready for primetime, but a very narrow and fragile "happy path" can be tested on Linux with
python3 installer/main.py --root ....This works and produces a usable install, but more work is needed for smooth cross-platform functionality. I will add more detail to this description, or in a future PR.