So you fucked up and did a git pull on A1111 and nothing works? Now it only gives you 10000 dependency errors? Then this guide is for you! Also unless you are a beginner, you are likely looking for step 6 of the hard route.
Edit 20230904: Updated attached requirement file. Remember it is for nvidia gpus. windows 10, cuda 118, python 3.10
Easily opening powershell
You can easily open a powershell window on a folder by doing a ctrl+shit+left click on a folder and selecting open powershell window here. That way you don't have to navigate there via cd.
First of all get yourself a git manager, don't be a barbarian who ends up using the git command line for a simple pull. That shit if for when git eats one of your stashes and you are trying to search for the reference id to restore it, not for day to day usage.
I highly recommend tortoise git https://tortoisegit.org/ it has served me faithfully for almost a decade.
This is how normal people do a git pull:
The Easy route
Well follow the next steps:
If you have automatic pull enabled in webui-user.bat disable it.
If you have a good enough internet connection and don't mind the waits simply delete the venv folder and launch A1111 again, all dependencies will be correctly downloaded.
Just kidding... mostly.
If you don't have a good internet connection or are feeling adventurous:
The hard route
For when you don't want to redownload everything and or wish to experiment with newer versions of the requirements.
Open a power shell or cmd move to your Scripts folders (stable-diffusion-webui\venv\Scripts) and execute either Activate.ps1 or Activate.bat depending on if you used ps or cmd(bat is for cmd). To run Activate.ps1 you can type .\Activate.
Type pip list and it will give you all the dependencies you have installed.
Compare them against Requirements.txt, requirements_versions.txt, requirements-test.txt
Update packages that require it by using pip Install -U packagename==version (like pip install -U accelerate==0.19) (the -U is case sensitive)
Update torch by using either pip or pip3 (both work exactly the same for most purposes)
For nvidia: pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/cu118 for cuda 11.8. Replace the cu118 for cu117 for the older cuda version.
For cpu only: pip3 install torch torchvision torchaudio
For Ati(linux only): pip3 install torch torchvision torchaudio --index-url https://download.pytorch.org/whl/rocm5.4.2
Alternatively you can copy an environment, to do that just go to where the file you wish to install is(or put the file wherever the activate files are) and do: install -r requirements.txt
I will upload my current environment be warned it is for windows 10, cuda 118, python 3.10.6. also be warned i might have some extra crap in there.
The why am i doing this to myself route
For when you need to locally download the stuff for reasons like installing in a closed system without internet access.
Repeat steps 1 to 3 from the previous route.
Python packages are called wheel files they end in .whl.
Download the necessary wheel files. remember that cuda enabled dependencies say cu118 or cu117. Cp-something like cp310 means the wheel file is for python 3.10.
For example the following repository contains torch wheels https://download.pytorch.org/whl/torch_stable.html suppose you are on windows 64 bits on cuda 118 and pithon 3.10 as is the standard for A1111 and you want the latest Torch(as of the creation of this guide 2.0.1). The file you want is: cu118/torch-2.0.1%2Bcu118-cp310-cp310-win_amd64.whl
Install the wheel directly by using: pip install http://websiteurl.com/filename.whl
or in case you already downloaded it: pip install C:/some-dir/some-file.whl
Now go forth and do it by hand for every one of your missing dependencies! You will have to look for each one of them in the internet.
Now you may be asking yourself what does the main image has to do with anything, to which the answer is I that like pretty ladies with huge boobs.