Error! The backend returned the http code: 500 (Windows machine, Automatic1111 integration)
ActuallyAuggie opened this issue ยท 6 comments
I'm getting a 500 error when trying to use this ui with Automatic1111 as the backend.
Tried on Windows 10 and 11 machines.
Tried latest commit, the recommended f2a4a2c3a672e22f088a7455d6039557370dd3f2, and several major steps back, up to 3 days ago. Same errors each time.
Python 3.10.6
pip 22.2.2
Traceback (most recent call last): File "D:\stable-diffusion-webui-1111\venv\lib\site-packages\gradio\routes.py", line 273, in run_predict output = await app.blocks.process_api( File "D:\stable-diffusion-webui-1111\venv\lib\site-packages\gradio\blocks.py", line 739, in process_api inputs = self.preprocess_data(fn_index, inputs, state) File "D:\stable-diffusion-webui-1111\venv\lib\site-packages\gradio\blocks.py", line 638, in preprocess_data processed_input.append(block.preprocess(raw_input[i])) File "D:\stable-diffusion-webui-1111\venv\lib\site-packages\gradio\components.py", line 2118, in preprocess return process_single_file(x) File "D:\stable-diffusion-webui-1111\venv\lib\site-packages\gradio\components.py", line 2088, in process_single_file f["name"], TypeError: string indices must be integers
I installed the backend automatic1111 on Windows and finally got the same error.
The fields of the API are not in the same order, around the fields added by the scripts.
Maybe because it loads the scripts in a different order in Linux and Windows.
Investigating...
That's it, if I print the order of the added scripts I have on Windows:
check filename: custom_code.py
check filename: img2imgalt.py
check filename: loopback.py
check filename: outpainting_mk_2.py
check filename: poor_mans_outpainting.py
check filename: prompts_from_file.py
check filename: prompt_matrix.py
check filename: sd_upscale.py
check filename: xy_grid.py
But on Linux it is not sorted:
Loading script: prompt_matrix.py
Loading script: loopback.py
Loading script: xy_grid.py
Loading script: poor_mans_outpainting.py
Loading script: sd_upscale.py
Loading script: prompts_from_file.py
Loading script: img2imgalt.py
Loading script: custom_code.py
Loading script: outpainting_mk_2.py
I'll make a PR on automatic1111 to fix this...
This unfortunately is not fixing the issue for me. Same error, both on my established install and on a fresh one.
I may be testing incorrectly, I'm fairly unfamiliar with git:
in the webui folder in a terminal:
git fetch origin pull/1276/head:testui
git checkout testui
./webui-user.bat
I can confirm that the scripts.py file is updated, so I think I'm doing the right thing.
possibly more interestingly, my sort order is different than your windows one:
'Loading script: custom_code.py
Loading script: img2imgalt.py
Loading script: loopback.py
Loading script: outpainting_mk_2.py
Loading script: poor_mans_outpainting.py
Loading script: prompt_matrix.py
Loading script: prompts_from_file.py
Loading script: sd_upscale.py
Loading script: xy_grid.py`
Sorry this is not yet fixed, the order of the fields are still defined according to my Linux order. I'm currently reordering them to the sorted order.
This should work now when selecting "Automatic1111 sorted" as the backend and using the PR to fix the sort order.
How to make it work right now:
- Run
git fetch origin pull/1276/head && git checkout FETCH_HEAD
in thestable-diffusion-webui
folder to have a version of automatic1111 with sorted scripts - Launch the automatic1111 webui
- go to https://diffusionui.com
- select "Automatic1111 sorted" in the dropdown at the top of the left panel
I hope it works for you. Please tell me if it's ok now.