anapnoe / stable-diffusion-webui-ux

Stable Diffusion web UI UX
GNU Affero General Public License v3.0
970 stars 58 forks source link

[Bug]: WebUI Crash on Startup #144

Closed Nyksia closed 1 year ago

Nyksia commented 1 year ago

Is there an existing issue for this?

What happened?

After commit 1e614d2, WebUI crashes with the following error.

Traceback (most recent call last): File "C:\Stable Diffusion\launch.py", line 370, in start() File "C:\Stable Diffusion\launch.py", line 365, in start webui.webui() File "C:\Stable Diffusion\webui.py", line 295, in webui shared.demo = modules.ui.create_ui() File "C:\Stable Diffusion\modules\ui.py", line 1660, in create_ui component = create_setting_component(k, elem_id) File "C:\Stable Diffusion\modules\ui.py", line 1551, in create_setting_component raise Exception(f'bad options item type: {t} for key {key}') Exception: bad options item type: <class 'list'> for key quicksettings

Steps to reproduce the problem

  1. Launch WebUI.
  2. It crashes on startup.

What should have happened?

It should've launched without issues.

Commit where the problem happens

1e614d2

What platforms do you use to access the UI ?

Windows

What browsers do you use to access the UI ?

Microsoft Edge

Command Line Arguments

Only --no-half-vae and --xformers.

List of extensions


Extension | URL | Version | Update -- | -- | -- | -- CFG-Schedule-for-Automatic1111-SD | https://github.com/guzuligo/CFG-Schedule-for-Automatic1111-SD.git | 84892c88 (Thu Mar 9 10:43:02 2023) | unknown a1111-sd-webui-lycoris | https://github.com/KohakuBlueleaf/a1111-sd-webui-lycoris.git | 1f3e452c (Tue May 9 12:30:54 2023) | unknown sd-dynamic-thresholding | https://github.com/mcmonkeyprojects/sd-dynamic-thresholding.git | c9721ab0 (Mon May 8 23:17:15 2023) | unknown sd-webui-ar | https://github.com/alemelis/sd-webui-ar.git | 9df49dc2 (Wed Apr 12 09:23:17 2023) | unknown sd-webui-controlnet | https://github.com/Mikubill/sd-webui-controlnet.git | c9c8ca6e (Sun May 7 17:15:00 2023) | unknown sd-webui-infinite-image-browsing | https://github.com/zanllp/sd-webui-infinite-image-browsing.git | 34388f00 (Tue May 9 18:39:11 2023) | unknown sd-webui-llul | https://github.com/hnmr293/sd-webui-llul.git | aa47b3ee (Thu May 4 16:14:34 2023) | unknown sd-webui-model-converter | https://github.com/Akegarasu/sd-webui-model-converter | d19e2816 (Sun Mar 26 06:36:49 2023) | unknown sd-webui-regional-prompter | https://github.com/hako-mikan/sd-webui-regional-prompter.git | 2dc66cbe (Tue May 9 12:49:30 2023) | unknown sd-webui-supermerger | https://github.com/hako-mikan/sd-webui-supermerger.git | 2c004060 (Tue May 2 10:00:48 2023) | unknown stable-diffusion-webui-images-browser | https://github.com/AlUlkesh/stable-diffusion-webui-images-browser.git | c751a9ee (Tue May 9 16:07:49 2023) | unknown stable-diffusion-webui-rembg | https://github.com/AUTOMATIC1111/stable-diffusion-webui-rembg.git | 64821f04 (Sun Mar 12 15:32:00 2023) | unknown stable-diffusion-webui-state | https://github.com/ilian6806/stable-diffusion-webui-state.git | 8560a9c9 (Mon May 8 13:24:04 2023) | unknown stable-diffusion-webui-wd14-tagger | https://github.com/toriato/stable-diffusion-webui-wd14-tagger.git | 3ba3a735 (Sat Mar 25 20:32:37 2023) | unknown ultimate-upscale-for-automatic1111 | https://github.com/Coyote-A/ultimate-upscale-for-automatic1111.git | 756bb505 (Fri May 5 00:22:21 2023) | unknown

Console logs

venv "C:\Stable Diffusion\venv\Scripts\Python.exe"
Python 3.10.6 (tags/v3.10.6:9c7b4bd, Aug  1 2022, 21:53:49) [MSC v.1932 64 bit (AMD64)]
Version: <none>
Commit hash: 1e614d2dd26bb9d74a978ffe2ddd4b20e4504f4e
Installing requirements

Launching Web UI with arguments: --xformers --no-half-vae
ControlNet v1.1.150
ControlNet v1.1.150
Image Browser: ImageReward is not installed, cannot be used.
Loading weights [195bf85a19] from C:\Stable Diffusion\models\Stable-diffusion\Moth Mix Twin Moonlight.safetensors
Creating model from config: C:\Stable Diffusion\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Loading VAE weights specified in settings: C:\Stable Diffusion\models\VAE\clearvae_main.safetensors
Applying xformers cross attention optimization.
Textual inversion embeddings loaded(13): aid28, bad-artist, bad-artist-anime, bad-hands-5, bad_prompt_version2, badv3, badv5, boring_e621, charturnerv2, deepnegative, deformityv6, easynegative, negative-hand
Model loaded in 4.0s (load weights from disk: 0.4s, create model: 0.6s, apply weights to model: 0.6s, apply half(): 0.6s, load VAE: 0.2s, move model to device: 0.6s, load textual inversion embeddings: 1.1s).
Loading weights [195bf85a19] from C:\Stable Diffusion\models\Stable-diffusion\Moth Mix Twin Moonlight.safetensors
Creating model from config: C:\Stable Diffusion\configs\v1-inference.yaml
LatentDiffusion: Running in eps-prediction mode
DiffusionWrapper has 859.52 M params.
Loading VAE weights specified in settings: C:\Stable Diffusion\models\VAE\clearvae_main.safetensors
Applying xformers cross attention optimization.
Model loaded in 2.7s (load weights from disk: 0.3s, create model: 0.4s, apply weights to model: 0.6s, apply half(): 0.6s, load VAE: 0.2s, move model to device: 0.6s).
Traceback (most recent call last):
  File "C:\Stable Diffusion\launch.py", line 370, in <module>
    start()
  File "C:\Stable Diffusion\launch.py", line 365, in start
    webui.webui()
  File "C:\Stable Diffusion\webui.py", line 295, in webui
    shared.demo = modules.ui.create_ui()
  File "C:\Stable Diffusion\modules\ui.py", line 1660, in create_ui
    component = create_setting_component(k, elem_id)
  File "C:\Stable Diffusion\modules\ui.py", line 1551, in create_setting_component
    raise Exception(f'bad options item type: {t} for key {key}')
Exception: bad options item type: <class 'list'> for key quicksettings
Press any key to continue . . .

Additional information

No response

Nyksia commented 1 year ago

@anapnoe I seem to have dug up the exact issue. There's no need to revert the change to quicksettings_list in shared.py. You do need to add to line ~1549 in ui.py so it doesn't crash it because it fails to recognize the component.

 elif t == list:
             comp = gr.List

It makes it possible to add things to quicksettings through the setting in User Interface, but it requires a UI reload to show in the tab and it also still leaves the buttons to add settings to quicksettings broken.

Nyksia commented 1 year ago

On second thought, the reason why buttons are broken is probably related to why it doesn't update the UI immediately.

anapnoe commented 1 year ago

fixed