AUTOMATIC1111 / stable-diffusion-webui

Stable Diffusion web UI
GNU Affero General Public License v3.0
135.67k stars 25.9k forks source link

[Bug]: UI was broken #12302

Closed LLKoder closed 11 months ago

LLKoder commented 11 months ago

Is there an existing issue for this?

What happened?

I did not use Automation 1111 for ~2-3 months, It was all ok before. Today I have runned it and see UI was broken (some buttons are very big). I try download the lastest version and try downgrade to v1.1 - nothign help me.

I try Python 3.10.6 and 3.10.11.

I see some files not load in browser, may be it help you to understand my problem.

I have no ideas what happened.

2023-08-04_15-52

2023-08-04_15-56

2023-08-04_16-49

2023-08-04_16-50

Steps to reproduce the problem

  1. Go to ....
  2. Press ....
  3. ...

What should have happened?

Correct UI.

Version or Commit where the problem happens

68f336b

What Python version are you running on ?

Python 3.10.x

What platforms do you use to access the UI ?

Windows

What device are you running WebUI on?

Nvidia GPUs (RTX 20 above)

Cross attention optimization

Automatic

What browsers do you use to access the UI ?

Mozilla Firefox, Google Chrome

Command Line Arguments

Launching Web UI with arguments: --theme dark --xformers --no-download-sd-model --ckpt-dir ...\Checkpoints

List of extensions

fresh WebUI - no extensions

Console logs

venv "...\.venv\Scripts\Python.exe"
Python 3.10.11 (tags/v3.10.11:7d4cc5a, Apr  5 2023, 00:38:17) [MSC v.1929 64 bit (AMD64)]
Commit hash: 72cd27a13587c9579942577e9e3880778be195f6
Installing requirements
Launching Web UI with arguments: --theme dark --xformers --no-download-sd-model --ckpt-dir ...\Checkpoints
Loading weights [ff1517b16b] from ...\Checkpoints\Adellanuki-Adellas_Abyss_Amalgamate.safetensors
Creating model from config: ...\stable-diffusion-webui\stable-diffusion-webui\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Applying xformers cross attention optimization.
Textual inversion embeddings loaded(0):
Model loaded in 3.6s (load weights from disk: 0.2s, create model: 0.5s, apply weights to model: 0.5s, apply half(): 0.6s, move model to device: 0.5s, load textual inversion embeddings: 1.1s).
Running on local URL:  http://127.0.0.1:7860

To create a public link, set `share=True` in `launch()`.
Startup time: 10.5s (import torch: 2.0s, import gradio: 1.1s, import ldm: 0.6s, other imports: 1.2s, load scripts: 1.0s, load SD checkpoint: 3.8s, create ui: 0.5s, gradio launch: 0.1s).

Additional information

No response

Kadah commented 11 months ago

Looks like your browser is blocking javascript. Check any ad blocking or no script browser extensions/plugins.

sharkDDD commented 11 months ago

The same error, hope to be solved

sharkDDD commented 11 months ago

The same error, I have been restarting the webui for about twenty times, then it worked. I dont know what happened, but restart for many times really work.

LLKoder commented 11 months ago

Looks like your browser is blocking javascript. Check any ad blocking or no script browser extensions/plugins.

I have some extensions in the Chrome, but I have no one extensions in Firefox, It's very fresh. I use it for Automatic 1111 and ComfyUI.

p.s. ComfyUI is ok.

LLKoder commented 11 months ago

I found solve. It happened because AUTOMATIC1111 or Gradio cannot work with symbolic links, relative paths... properly. I have symbolic links (C:) to directory with AUTOMATIC1111 (E:). Once upon a time it worked but not now. I use symbolic links in Windows (not shortcut), I don't know how it behaves in Linux but think it's the same.

I execute AUTOMATIC1111 from E:\ directly - all ok.

Keep in mind AUTOMATIC1111 or Gradio does not flexibility. It's bug a developer which don't fix it in time. :(

catboxanon commented 11 months ago

This is not a bug. It's a security feature that is part of Gradio. Add your actual directory where the program is installed to the --gradio-allowed-path command line argument and that will resolve it.

idk500 commented 11 months ago

use --subpath to add ur path, can resolve.

LLKoder commented 11 months ago

@catboxanon I didn't find this parameter in manual. Where can I read about it?

catboxanon commented 11 months ago

You're right, looks like it's missing from the wiki. I added it now. https://github.com/AUTOMATIC1111/stable-diffusion-webui/wiki/Command-Line-Arguments-and-Settings

That page probably needs to be updated further, but you can see all current command line args here: https://github.com/AUTOMATIC1111/stable-diffusion-webui/blob/master/modules/cmd_args.py

Kadah commented 11 months ago

This is not a bug. It's a security feature that is part of Gradio. Add your actual directory where the program is installed to the --gradio-allowed-path command line argument and that will resolve it.

Is this a Windows only affected change? I've been running dev post Gradio 3.39 update since last week without running in to this and I heavily use symlinks.

LLKoder commented 11 months ago

This Is a affected change for any Gradio version for me. As I said before It worked many months with links but one day... I'm not sure that it Gradio, it's maybe Automatic 1111. In any cases, if it's a security feature then it's very strange worked security feature - bug.

catboxanon commented 11 months ago

Not sure why it quit working for you one day, but it is Gradio, as the error message you posted originates from it. It is unrelated to A1111. https://github.com/gradio-app/gradio/blame/4ee9c1b7087c00bc961f2ad6b4612d587685ba67/gradio/routes.py#L371

LLKoder commented 11 months ago

@catboxanon

Today, I relocated config files and set COMMANDLINE_ARGS in webui-user.bat.

--ui-settings-file E:\\one\\stable-diffusion-webui\\config.json --ui-config-file E:\\one\\stable-diffusion-webui\\ui-config.json --styles-file E:\\one\\stable-diffusion-webui\\styles.csv

WebUI: E:\two\stable-diffusion-webui

Now I have the same issue, UI is broken but I have no error now (as at screenshots). If I rollback all actions - all ok. Why?

yyhhenry commented 10 months ago

I encountered the same error again on Windows, because I put it in a folder whose name starts with a dot (.), such as C:/.bin/stable-diffusion-webui. However, it worked fine when I reverted to version v1.5.2. So I guess it might be related to some update of gradio.