mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
8c15d14099
We have had a few bugs with v4 related to file encodings, especially on Windows. Windows uses its own character encodings instead of `utf-8`, often `cp1252`. Some characters cannot be decoded using `utf-8`, causing `UnicodeDecodeError`. There are a couple places where this can cause problems: - In the installer bootstrap, we install or upgrade `pip` and decode the result, using `subprocess`. The input to this includes the user's home dir. In #6105, the user had one of the problematic characters in their username. `subprocess` attempts and fails to decode the username, which crashes the installer. To fix this, we need to use `locale.getpreferredencoding()` when executing the command. - Similarly, in the model install service and config class, we attempt to load a yaml config file. If a problematic character is in the path to the file (which often includes the user's home dir), we can get the same error. One example is #6129 in which the models.yaml migration fails. To fix this, we need to open the file with `locale.getpreferredencoding()`. |
||
---|---|---|
.. | ||
lib | ||
templates | ||
create_installer.sh | ||
install.bat.in | ||
install.sh.in | ||
readme.txt | ||
tag_release.sh | ||
WinLongPathsEnabled.reg |
InvokeAI Project homepage: https://github.com/invoke-ai/InvokeAI Preparations: You will need to install Python 3.10 or higher for this installer to work. Instructions are given here: https://invoke-ai.github.io/InvokeAI/installation/INSTALL_AUTOMATED/ Before you start the installer, please open up your system's command line window (Terminal or Command) and type the commands: python --version If all is well, it will print "Python 3.X.X", where the version number is at least 3.10.*, and not higher than 3.11.*. If this works, check the version of the Python package manager, pip: pip --version You should get a message that indicates that the pip package installer was derived from Python 3.10 or 3.11. For example: "pip 22.0.1 from /usr/bin/pip (python 3.10)" Long Paths on Windows: If you are on Windows, you will need to enable Windows Long Paths to run InvokeAI successfully. If you're not sure what this is, you almost certainly need to do this. Simply double-click the "WinLongPathsEnabled.reg" file located in this directory, and approve the Windows warnings. Note that you will need to have admin privileges in order to do this. Launching the installer: Windows: double-click the 'install.bat' file (while keeping it inside the InvokeAI-Installer folder). Linux and Mac: Please open the terminal application and run './install.sh' (while keeping it inside the InvokeAI-Installer folder). The installer will create a directory of your choice and install the InvokeAI application within it. This directory contains everything you need to run invokeai. Once InvokeAI is up and running, you may delete the InvokeAI-Installer folder at your convenience. For more information, please see https://invoke-ai.github.io/InvokeAI/installation/INSTALL_AUTOMATED/