stable-diffusion-webui icon indicating copy to clipboard operation
stable-diffusion-webui copied to clipboard

ERROR: Exception in ASGI application

Open f-rank opened this issue 2 years ago • 15 comments

Is there an existing issue for this?

  • [X] I have searched the existing issues and checked the recent builds/commits

What happened?

Just came across this, after some hours generating.

ERROR: Exception in ASGI application Traceback (most recent call last): File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\uvicorn\protocols\http\h11_impl.py", line 407, in run_asgi result = await app( # type: ignore[func-returns-value] File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 78, in call return await self.app(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\fastapi\applications.py", line 270, in call await super().call(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\applications.py", line 124, in call await self.middleware_stack(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 184, in call raise exc File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\errors.py", line 162, in call await self.app(scope, receive, _send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\gzip.py", line 24, in call await responder(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\gzip.py", line 44, in call await self.app(scope, receive, self.send_with_gzip) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in call raise exc File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in call await self.app(scope, receive, sender) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in call raise e File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 706, in call await route.handle(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 276, in handle await self.app(scope, receive, send) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\routing.py", line 66, in app response = await func(request) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\fastapi\routing.py", line 237, in app raw_response = await run_endpoint_function( File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\fastapi\routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\starlette\concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\anyio\to_thread.py", line 31, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\anyio_backends_asyncio.py", line 937, in run_sync_in_worker_thread return await future File "d:\WORK\conda_envs\automatic\stable-diffusion-webui\venv\lib\site-packages\anyio_backends_asyncio.py", line 867, in run result = context.run(func, *args) File "D:\WORK\conda_envs\automatic\stable-diffusion-webui\modules\progress.py", line 73, in progressapi progress += 1 / shared.state.job_count * shared.state.sampling_step / shared.state.sampling_steps ZeroDivisionError: division by zero "

Steps to reproduce the problem

Unfortunately it looks random. Generated for hours until hit by it.

What should have happened?

No error.

Commit where the problem happens

52f6e94338f31c286361802b08ee5210b8244141

What platforms do you use to access UI ?

Windows

What browsers do you use to access the UI ?

Microsoft Edge

Command Line Arguments

--xformers --opt-channelslast

Additional information, context and logs

No response

f-rank avatar Jan 17 '23 00:01 f-rank

I have updated today and i am getting this error too, but i get it just for acceding to the local URL in the web browser.

Dravoss avatar Jan 18 '23 12:01 Dravoss

me too, also raise after launch the web page

LieDeath avatar Jan 18 '23 14:01 LieDeath

following the other thread suggestion i disabled one not up to date extension and the error went away.

Dravoss avatar Jan 18 '23 14:01 Dravoss

I followed that threat but I don't actually have that extension so i don't know what else it could be, i removed all other extensions and the problem was still there.

ptrprkr avatar Jan 28 '23 11:01 ptrprkr

Hey weird question, do you have Save text information about generation parameters as chunks to png files disabled?

I was troubleshooting another plugin that errored out in a similar fashion (with the ERROR: Exception in ASGI application) and I fixed it by re-enabling that setting.

That plugin was attempting to scrape metadata from the generated .png and would return a null (since I had that setting disabled) and crash the entire plugin.

Not sure if it applies to this exact problem (as your error is slightly different) but it might fix it for you.

remghoost avatar Jan 30 '23 20:01 remghoost

@remghoost I have that option enabled.

f-rank avatar Jan 31 '23 03:01 f-rank

To everyone claiming that disabling an extension fixes it, that is likely just because you restarted the server. In my experience, this happens after several days of keeping the A1111 server open.

My theory (but it's just a theory) is that the model is getting evicted from VRAM after a while. Restarting the server fixes it, but since I want to use it as a server via the API, it's impossible to make this restart automatically. Even as a workaround if the application could detect this failure and restart itself, that would be helpful.

Keavon avatar Feb 13 '23 04:02 Keavon

I faced the same issue, and by trial and error found out (at least for me) the issue was with xformers. removing the --xformers argument disables xformers and the error went away.

Try it.

seems to be problem with latest update. Hopefully they fix this, cause else we won't be able to use xformers.

extra2AB avatar Feb 14 '23 15:02 extra2AB

https://youtu.be/YuFFmcqlZiU?t=6 "why must there always be a problem!?"

Natotela avatar Feb 20 '23 14:02 Natotela

I got this error from going to img2img tab and uploading a .png image.

jariahtiainen avatar Mar 14 '23 07:03 jariahtiainen

i got it when trying to update extensions

beltaro avatar Mar 18 '23 18:03 beltaro

Been getting this error for the last week or so. Havent been able to find the cause. It all still works, but just strange that theres an error. Seems to happen when refreshing the web page in browser.

ColorfanXP avatar Mar 20 '23 04:03 ColorfanXP

I also have the same issue with my API running on Digital Ocean. I tested the endpoint locally and ran in to the same issue.

ERROR: Exception in ASGI application Traceback (most recent call last): File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\uvicorn\protocols\http\httptools_impl.py", line 404, in run_asgi result = await app( # type: ignore[func-returns-value] File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 78, in call
return await self.app(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\fastapi\applications.py", line 270, in call await super().call(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\applications.py", line 124, in call await self.middleware_stack(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\middleware\errors.py", line 184, in call
raise exc File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\middleware\errors.py", line 162, in call
await self.app(scope, receive, _send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\middleware\cors.py", line 84, in call await self.app(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\middleware\exceptions.py", line 75, in call
raise exc File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\middleware\exceptions.py", line 64, in call
await self.app(scope, receive, sender) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in call
raise e File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in call
await self.app(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\routing.py", line 680, in call await route.handle(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\routing.py", line 275, in handle await self.app(scope, receive, send) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\routing.py", line 65, in app response = await func(request) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\fastapi\routing.py", line 231, in app raw_response = await run_endpoint_function( File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\fastapi\routing.py", line 162, in run_endpoint_function
return await run_in_threadpool(dependant.call, **values) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\starlette\concurrency.py", line 41, in run_in_threadpool
return await anyio.to_thread.run_sync(func, *args) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\anyio\to_thread.py", line 31, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\anyio_backends_asyncio.py", line 937, in run_sync_in_worker_thread return await future File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\anyio_backends_asyncio.py", line 867, in run result = context.run(func, *args) File "C:\Users\hp\Documents\Our Documents\Personal Development\Projects\Personal Projects\Election-Campaign-Application-Phase2-Implementation.\app\main.py", line 82, in run_prediction message = predict_sentiment() File "C:\Users\hp\Documents\Our Documents\Personal Development\Projects\Personal Projects\Election-Campaign-Application-Phase2-Implementation.\app\main.py", line 45, in predict_sentiment prediction = model.predict(ind_var, verbose=False) File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\keras\utils\traceback_utils.py", line 70, in error_handler
raise e.with_traceback(filtered_tb) from None File "C:\Users\hp\AppData\Local\Programs\Python\Python310\lib\site-packages\keras\engine\training.py", line 2407, in predict raise ValueError( ValueError: Unexpected result of predict_function (Empty batch_outputs). Please use Model.compile(..., run_eagerly=True), or tf.config.run_functions_eagerly(True) for more information of where went wrong, or file a issue/bug to tf.keras.

dub-em avatar Apr 07 '23 10:04 dub-em

I faced the same issue, and by trial and error found out (at least for me) the issue was with xformers. removing the --xformers argument disables xformers and the error went away.

Try it.

seems to be problem with latest update. Hopefully they fix this, cause else we won't be able to use xformers. fixed by this method.thank u .after i installed some plugins i encountered this issue.

hfchensq1 avatar Apr 12 '23 14:04 hfchensq1

I am getting this problem today, probably something to do with Cuda and Torch, I updated Cuda to 11.8 yesterday and I'm facing this.

vsatyamesc avatar Apr 13 '23 16:04 vsatyamesc

I was running into this issue this evening, and tried removing xformers first, which wasn't it. I then disabled all of my extensions, and the issue went away. After testing each one-by-one, I discovered it was actually two of them causing it, both "multidiffusion-upscaler-for-automatic1111" and "stable-diffusion-webui-vectorstudio". Disabling those solved the issue for me.

brittnell avatar Apr 21 '23 03:04 brittnell

I was running into this issue this evening, and tried removing xformers first, which wasn't it. I then disabled all of my extensions, and the issue went away. After testing each one-by-one, I discovered it was actually two of them causing it, both "multidiffusion-upscaler-for-automatic1111" and "stable-diffusion-webui-vectorstudio". Disabling those solved the issue for me.

Thanks for this. Disabling "stable-diffusion-webui-vectorstudio" fixed it for me as well.

jmontgomeryCSE avatar Jun 01 '23 15:06 jmontgomeryCSE

it [00:00, ?it/s] 2023-07-25 13:31:03,153 - ControlNet - INFO - ControlNet v1.1.233 ControlNet preprocessor location: /home/sj/stable-diffusion-webui/extensions/sd-webui-controlnet/annotator/downloads 2023-07-25 13:31:03,213 - ControlNet - INFO - ControlNet v1.1.233 Checkpoint 2.5D/rpg_V4.safetensors [e04b020012] not found; loading fallback v1-5-pruned-emaonly.safetensors [6ce0161689] Loading weights [6ce0161689] from /home/sj/stable-diffusion-webui/models/Stable-diffusion/v1-5-pruned-emaonly.safetensors Creating model from config: /home/sj/stable-diffusion-webui/configs/v1-inference.yaml LatentDiffusion: Running in eps-prediction mode Deforum ControlNet support: enabled ERROR: Exception in ASGI application UnicodeEncodeError: 'utf-8' codec can't encode characters in position 20-21: surrogates not allowed

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi result = await app( # type: ignore[func-returns-value] File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in call await super().call(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in call await self.app(scope, receive, _send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in call await self.app(scope, receive, sender) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in call raise e File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in call await route.handle(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app response = await func(request) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app raw_response = await run_endpoint_function( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 251, in main return templates.TemplateResponse( File "/home/sj/stable-diffusion-webui/modules/ui_gradio_extensions.py", line 59, in template_response res = shared.GradioTemplateResponseOriginal(*args, **kwargs) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 113, in TemplateResponse return _TemplateResponse( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 39, in init content = template.render(context) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render self.environment.handle_exception() File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception raise rewrite_traceback_stack(source=source) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/templates/frontend/index.html", line 41, in top-level template code File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 83, in toorjson ORJSONResponse._render_str(value) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 78, in _render_str return ORJSONResponse._render(content).decode("utf-8") File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 67, in _render return orjson.dumps( TypeError: str is not valid UTF-8: surrogates not allowed preload_extensions_git_metadata for 21 extensions took 0.58s DiffusionWrapper has 859.52 M params. ERROR: Exception in ASGI application UnicodeEncodeError: 'utf-8' codec can't encode characters in position 20-21: surrogates not allowed

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi result = await app( # type: ignore[func-returns-value] File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in call await super().call(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in call await self.app(scope, receive, _send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in call await self.app(scope, receive, sender) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in call raise e File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in call await route.handle(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app response = await func(request) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app raw_response = await run_endpoint_function( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 251, in main return templates.TemplateResponse( File "/home/sj/stable-diffusion-webui/modules/ui_gradio_extensions.py", line 59, in template_response res = shared.GradioTemplateResponseOriginal(*args, **kwargs) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 113, in TemplateResponse return _TemplateResponse( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 39, in init content = template.render(context) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render self.environment.handle_exception() File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception raise rewrite_traceback_stack(source=source) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/templates/frontend/index.html", line 41, in top-level template code File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 83, in toorjson ORJSONResponse._render_str(value) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 78, in _render_str return ORJSONResponse._render(content).decode("utf-8") File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 67, in _render return orjson.dumps( TypeError: str is not valid UTF-8: surrogates not allowed ERROR: Exception in ASGI application UnicodeEncodeError: 'utf-8' codec can't encode characters in position 20-21: surrogates not allowed

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi result = await app( # type: ignore[func-returns-value] File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in call await super().call(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in call await self.app(scope, receive, _send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in call await self.app(scope, receive, sender) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in call raise e File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in call await route.handle(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app response = await func(request) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app raw_response = await run_endpoint_function( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 251, in main return templates.TemplateResponse( File "/home/sj/stable-diffusion-webui/modules/ui_gradio_extensions.py", line 59, in template_response res = shared.GradioTemplateResponseOriginal(*args, **kwargs) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 113, in TemplateResponse return _TemplateResponse( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 39, in init content = template.render(context) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render self.environment.handle_exception() File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception raise rewrite_traceback_stack(source=source) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/templates/frontend/index.html", line 41, in top-level template code File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 83, in toorjson ORJSONResponse._render_str(value) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 78, in _render_str return ORJSONResponse._render(content).decode("utf-8") File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 67, in _render return orjson.dumps( TypeError: str is not valid UTF-8: surrogates not allowed Applying attention optimization: xformers... done. Textual inversion embeddings loaded(0): Model loaded in 2.9s (load weights from disk: 0.6s, create model: 1.4s, apply weights to model: 0.4s, apply half(): 0.3s). ERROR: Exception in ASGI application UnicodeEncodeError: 'utf-8' codec can't encode characters in position 20-21: surrogates not allowed

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi result = await app( # type: ignore[func-returns-value] File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in call await super().call(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in call await self.app(scope, receive, _send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in call await self.app(scope, receive, sender) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in call raise e File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in call await route.handle(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app response = await func(request) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app raw_response = await run_endpoint_function( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 251, in main return templates.TemplateResponse( File "/home/sj/stable-diffusion-webui/modules/ui_gradio_extensions.py", line 59, in template_response res = shared.GradioTemplateResponseOriginal(*args, **kwargs) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 113, in TemplateResponse return _TemplateResponse( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 39, in init content = template.render(context) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render self.environment.handle_exception() File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception raise rewrite_traceback_stack(source=source) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/templates/frontend/index.html", line 41, in top-level template code File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 83, in toorjson ORJSONResponse._render_str(value) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 78, in _render_str return ORJSONResponse._render(content).decode("utf-8") File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 67, in _render return orjson.dumps( TypeError: str is not valid UTF-8: surrogates not allowed ERROR: Exception in ASGI application UnicodeEncodeError: 'utf-8' codec can't encode characters in position 20-21: surrogates not allowed

The above exception was the direct cause of the following exception:

Traceback (most recent call last): File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi result = await app( # type: ignore[func-returns-value] File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call return await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/applications.py", line 273, in call await super().call(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 184, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/errors.py", line 162, in call await self.app(scope, receive, _send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/cors.py", line 84, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 79, in call raise exc File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/middleware/exceptions.py", line 68, in call await self.app(scope, receive, sender) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 21, in call raise e File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/middleware/asyncexitstack.py", line 18, in call await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 718, in call await route.handle(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/routing.py", line 66, in app response = await func(request) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 237, in app raw_response = await run_endpoint_function( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/fastapi/routing.py", line 165, in run_endpoint_function return await run_in_threadpool(dependant.call, **values) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/concurrency.py", line 41, in run_in_threadpool return await anyio.to_thread.run_sync(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/to_thread.py", line 33, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 877, in run_sync_in_worker_thread return await future File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/anyio/_backends/_asyncio.py", line 807, in run result = context.run(func, *args) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 251, in main return templates.TemplateResponse( File "/home/sj/stable-diffusion-webui/modules/ui_gradio_extensions.py", line 59, in template_response res = shared.GradioTemplateResponseOriginal(*args, **kwargs) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 113, in TemplateResponse return _TemplateResponse( File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/starlette/templating.py", line 39, in init content = template.render(context) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 1301, in render self.environment.handle_exception() File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/jinja2/environment.py", line 936, in handle_exception raise rewrite_traceback_stack(source=source) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/templates/frontend/index.html", line 41, in top-level template code File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 83, in toorjson ORJSONResponse._render_str(value) File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 78, in _render_str return ORJSONResponse._render(content).decode("utf-8") File "/home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/routes.py", line 67, in _render return orjson.dumps( TypeError: str is not valid UTF-8: surrogates not allowed ╭─────────────────────────────── Traceback (most recent call last) ────────────────────────────────╮ │ /home/sj/stable-diffusion-webui/launch.py:38 in │ │ │ │ 35 │ │ 36 │ │ 37 if name == "main": │ │ ❱ 38 │ main() │ │ 39 │ │ │ │ /home/sj/stable-diffusion-webui/launch.py:34 in main │ │ │ │ 31 │ if args.test_server: │ │ 32 │ │ configure_for_tests() │ │ 33 │ │ │ ❱ 34 │ start() │ │ 35 │ │ 36 │ │ 37 if name == "main": │ │ │ │ /home/sj/stable-diffusion-webui/modules/launch_utils.py:344 in start │ │ │ │ 341 │ if '--nowebui' in sys.argv: │ │ 342 │ │ webui.api_only() │ │ 343 │ else: │ │ ❱ 344 │ │ webui.webui() │ │ 345 │ │ │ │ /home/sj/stable-diffusion-webui/webui.py:390 in webui │ │ │ │ 387 │ │ │ │ 388 │ │ gradio_auth_creds = list(get_gradio_auth_creds()) or None │ │ 389 │ │ │ │ ❱ 390 │ │ app, local_url, share_url = shared.demo.launch( │ │ 391 │ │ │ share=cmd_opts.share, │ │ 392 │ │ │ server_name=server_name, │ │ 393 │ │ │ server_port=cmd_opts.port, │ │ │ │ /home/sj/stable-diffusion-webui/venv/lib/python3.10/site-packages/gradio/blocks.py:1806 in │ │ launch │ │ │ │ 1803 │ │ # If running in a colab or not able to access localhost, │ │ 1804 │ │ # a shareable link must be created. │ │ 1805 │ │ if _frontend and (not networking.url_ok(self.local_url)) and (not self.share): │ │ ❱ 1806 │ │ │ raise ValueError( │ │ 1807 │ │ │ │ "When localhost is not accessible, a shareable link must be created. Ple │ │ 1808 │ │ │ ) │ │ 1809 │ ╰─────────────────────────────────────────────────────────────────────────────────────────────────╯ ValueError: When localhost is not accessible, a shareable link must be created. Please set share=True or check your proxy settings to allow access to localhost.

This problem is caused by the module /stable-diffusion-webui/models that loads the model with a Chinese mark, but it will not be reflected in the win system. This problem will be encountered in ubuntu. How to solve this problem, you need to delete the model marked in Chinese, or change the name.

ME LM3JMNJQOI~G})(%%K@U

a373648449 avatar Jul 25 '23 06:07 a373648449

I've this error after an hour oob is active and i don't use xformers

grigio avatar Jul 31 '23 12:07 grigio

I also have the issue with my API running . I tested the endpoint locally and ran in to the same issue.

ERROR: Exception in ASGI application Traceback (most recent call last): File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\uvicorn\protocols\http\httptools_impl.py", line 426, in run_asgi result = await app( # type: ignore[func-returns-value] ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in call return await self.app(scope, receive, send) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\fastapi\applications.py", line 289, in call await super().call(scope, receive, send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\applications.py", line 122, in call await self.middleware_stack(scope, receive, send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\middleware\errors.py", line 184, in call raise exc File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\middleware\errors.py", line 162, in call await self.app(scope, receive, _send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\middleware\exceptions.py", line 79, in call raise exc File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\middleware\exceptions.py", line 68, in call await self.app(scope, receive, sender) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\fastapi\middleware\asyncexitstack.py", line 20, in call raise e File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\fastapi\middleware\asyncexitstack.py", line 17, in call await self.app(scope, receive, send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\routing.py", line 718, in call await route.handle(scope, receive, send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\routing.py", line 276, in handle await self.app(scope, receive, send) File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\starlette\routing.py", line 66, in app response = await func(request) ^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\fastapi\routing.py", line 273, in app raw_response = await run_endpoint_function( ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\fastapi\routing.py", line 190, in run_endpoint_function return await dependant.call(**values) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\app.py", line 111, in query llm = GPT4All(model=model_path, n_ctx=model_n_ctx, backend='gptj', callbacks=callbacks, verbose=False) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "pydantic\main.py", line 339, in pydantic.main.BaseModel.init File "pydantic\main.py", line 1102, in pydantic.main.validate_model File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\langchain\llms\gpt4all.py", line 169, in validate_environment values["client"] = GPT4AllModel( ^^^^^^^^^^^^^ File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\pygpt4all\models\gpt4all_j.py", line 47, in init super(GPT4All_J, self).init(model_path=model_path, File "C:\Users\Administrator\OneDrive\Desktop\privateGpt\venv\Lib\site-packages\pygptj\model.py", line 58, in init raise Exception(f"File {model_path} not found!") Exception: File models\ggml-gpt4all-j-v1.3-groovy.bin not found!

arvind9140 avatar Aug 10 '23 20:08 arvind9140

when i use chatglm2-6b,this error will response but don‘t influence

1172274374 avatar Aug 16 '23 07:08 1172274374

https://www.youtube.com/watch?v=jyWo7dSpvL8 This video solve my problem.

jeremy641 avatar Aug 20 '23 16:08 jeremy641

TLDR: The problem for me was miaoshouai-assistant. Removed it, deleted venv folder. Works now.

Longer version: I had tried everything I found on this page and a few others with no luck. I can't say whether or not anything on this page helped my solution mentioned here work better or if there was no effect. All I know is the fixes didn't work until I removed the miaoshouai-assistant extension. I really liked that extension and hope it's updated to working again for me.

Steps I performed to get my stable diffusion working again:

  • Delete the venv folder
  • Delete the Miaoshouai-assistant folder in /extensions
  • Run webui-user.bat

The venv folder was rebuilt and started working. The reason I take extra care to point this out is because I tried running SD with no extensions in the /extensions folder and still got the same error. I can only guess that miaoshouai-assistant puts something in the folder that causes the issue, or requires a dependency that causes the issue.

Hope this helps ♥

Winters-Glade avatar Sep 23 '23 10:09 Winters-Glade

Just want to throw my anecdote into the mix. I've encountered this issue twice, and in both cases, the "/info" endpoint starts throwing 500 errors, causing all of the other functionality in a1111 to fail. If I delete the venv folder and restart, the problem goes away for awhile.

In both cases when I encountered this issue, I was using some PNG Info functionality, and I do have Miaoshou-assistant installed and enabled.

dejayc avatar Sep 23 '23 16:09 dejayc

UPDATE: I discovered that I had an older version of Miaoshou-assistant installed, which was apparently installing an older version of gradio, which in turn installed an older version of gradio_client, which caused issues such as:

AttributeError: module 'gradio_client.utils' has no attribute 'SKIP_COMPONENTS'. Did you mean: 'STATE_COMPONENT'?

So the weird behavior was this: when I created a new venv from scratch, it would first install version 0.5.0 of gradio_client, but then I would see the following message in the console:

Installing Miaoshou assistant requirement: gradio_client==0.2.7

Upon seeing this message, I would execute:

cat venv/python3.10/Lib/site-packages/gradio_client/version.txt
0.5.0

Which suggests that gradio_client 0.2.7 WAS NOT, in fact, installed when first running A1111, and everything would work properly. However, upon restarting A1111, and seeing the same message about gradio_client 0.2.7, re-running that same command revealed that gradio_client 0.2.7 WAS installed:

cat venv/python3.10/Lib/site-packages/gradio_client/version.txt
0.2.7

I don't know how to make extensions each run their own versions of a library, instead of changing the global package used by all the other modules in the venv, so I tried upgrading Miaoshou-assistant:

cd extensions/miaoshouai-assistant
git checkout -- .
git pull

Upon restarting A1111, miaoshouai-assistant is now using gradio_client 0.5.0:

Installing Miaoshou assistant requirement: gradio_client==0.5.0
cat venv/python3.10/Lib/site-packages/gradio_client/version.txt
0.5.0

All of my A1111 became resolved after this upgrade.

dejayc avatar Sep 23 '23 20:09 dejayc

I don't know if this helps but I'm no longer getting the Error after removing the FaceSwapLab extension from latest version of A1111

thatjimupnorth avatar Oct 07 '23 17:10 thatjimupnorth

[+] Running 1/0 ✔ Container movies Created 0.0s Attaching to movies movies | INFO: Started server process [1] movies | INFO: Waiting for application startup. movies | INFO: Application startup complete. movies | INFO: Uvicorn running on http://0.0.0.0:8008 (Press CTRL+C to quit) movies | INFO: 172.19.0.1:46956 - "GET /docs HTTP/1.1" 200 OK movies | INFO: 172.19.0.1:46956 - "GET /openapi.json HTTP/1.1" 200 OK movies | INFO: 172.19.0.1:43058 - "GET /movies HTTP/1.1" 200 OK movies | INFO: 172.19.0.1:34900 - "POST /movies HTTP/1.1" 500 Internal Server Error movies | ERROR: Exception in ASGI application movies | Traceback (most recent call last): movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 1819, in _execute_context movies | self.dialect.do_execute( movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/default.py", line 732, in do_execute movies | cursor.execute(statement, parameters) movies | psycopg2.errors.UndefinedColumn: column movies_table.director_id does not exist movies | LINE 1: ...able.popularity_99 AS movies_table_popularity_99, movies_tab... movies | ^ movies | HINT: Perhaps you meant to reference the column "movies_table.director". movies | movies | movies | The above exception was the direct cause of the following exception: movies | movies | Traceback (most recent call last): movies | File "/usr/local/lib/python3.11/site-packages/uvicorn/protocols/http/h11_impl.py", line 408, in run_asgi movies | result = await app( # type: ignore[func-returns-value] movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/uvicorn/middleware/proxy_headers.py", line 84, in call movies | return await self.app(scope, receive, send) movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/fastapi/applications.py", line 292, in call movies | await super().call(scope, receive, send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/applications.py", line 122, in call movies | await self.middleware_stack(scope, receive, send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/errors.py", line 184, in call movies | raise exc movies | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/errors.py", line 162, in call movies | await self.app(scope, receive, _send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 79, in call movies | raise exc movies | File "/usr/local/lib/python3.11/site-packages/starlette/middleware/exceptions.py", line 68, in call movies | await self.app(scope, receive, sender) movies | File "/usr/local/lib/python3.11/site-packages/fastapi/middleware/asyncexitstack.py", line 20, in call movies | raise e movies | File "/usr/local/lib/python3.11/site-packages/fastapi/middleware/asyncexitstack.py", line 17, in call movies | await self.app(scope, receive, send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 718, in call movies | await route.handle(scope, receive, send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 276, in handle movies | await self.app(scope, receive, send) movies | File "/usr/local/lib/python3.11/site-packages/starlette/routing.py", line 66, in app movies | response = await func(request) movies | ^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/fastapi/routing.py", line 273, in app movies | raw_response = await run_endpoint_function( movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/fastapi/routing.py", line 190, in run_endpoint_function movies | return await dependant.call(**values) movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/movie_docker/main.py", line 187, in create_movies movies | existing_movie = db.query(models.Movies).filter(models.Movies.name == movie_data.name).first() movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/orm/query.py", line 2819, in first movies | return self.limit(1)._iter().first() movies | ^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/orm/query.py", line 2903, in _iter movies | result = self.session.execute( movies | ^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/orm/session.py", line 1712, in execute movies | result = conn._execute_20(statement, params or {}, execution_options) movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 1631, in _execute_20 movies | return meth(self, args_10style, kwargs_10style, execution_options) movies |
movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/sql/elements.py", line 332, in _execute_on_connection movies | return connection._execute_clauseelement( movies | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 1498, in _execute_clauseelement movies | ret = self._execute_context( movies | ^^^^^^^^^^^^^^^^^^^^^^ movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 1862, in _execute_context movies | self.handle_dbapi_exception( movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 2043, in handle_dbapi_exception movies | util.raise( movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/util/compat.py", line 208, in raise movies | raise exception movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/base.py", line 1819, in _execute_context movies | self.dialect.do_execute( movies | File "/usr/local/lib/python3.11/site-packages/sqlalchemy/engine/default.py", line 732, in do_execute movies | cursor.execute(statement, parameters) movies | sqlalchemy.exc.ProgrammingError: (psycopg2.errors.UndefinedColumn) column movies_table.director_id does not exist movies | LINE 1: ...able.popularity_99 AS movies_table_popularity_99, movies_tab... movies | ^ movies | HINT: Perhaps you meant to reference the column "movies_table.director". movies | movies | [SQL: SELECT movies_table.id AS movies_table_id, movies_table.popularity_99 AS movies_table_popularity_99, movies_table.director_id AS movies_table_director_id, movies_table.genre AS movies_table_genre, movies_table.imdb_score AS movies_table_imdb_score, movies_table.name AS movies_table_name movies | FROM movies_table movies | WHERE movies_table.name = %(name_1)s movies | LIMIT %(param_1)s] movies | [parameters: {'name_1': 'the wizard of oz', 'param_1': 1}] movies | (Background on this error at: https://sqlalche.me/e/14/f405) movies |

bhattronak avatar Oct 11 '23 16:10 bhattronak

Im a bit late to the party but i am quite sure i know why the error occurs (one of multiple reason possibly>)

I was stupid and somehow managed to give pytorch's .PTH extension a default executable. Now these file are kind of just symlinks i think so that royally srewed my entire computer over.

That the reaspn why some SD webui extensions give errors. because the models they use are linked by as .PTH files instead of the full weight.

Now luckily we are developers and i totally didnt sspend an hour figuring this out.

in you're regedit you are able to change extension values back to undefined.

HKEY_CURRENT_USER\Software\Microsoft\Windows\CurrentVersion\Explorer\FileExts

Screenshot_1

as u can see i managed to first assign another weight as default. then i proceeded to bind it to .exe.

fix this by the enter the folder nameed as the extensions properties. clicking advanced and removing all the unwanted entries (in my case me 3 times 2 by accident)

Screenshot_2

hope thats reason (and possibly other weird py extensions)

404Luuk avatar Jan 01 '24 04:01 404Luuk

It would be amazing if the error messages would say which extensions are causing the issues.

MNeMoNiCuZ avatar Jan 07 '24 16:01 MNeMoNiCuZ

I have the same issue but idk how to resolve it.

ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\protocols\websockets\websockets_impl.py", line 250, in run_asgi
    result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\errors.py", line 149, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\cors.py", line 76, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\gzip.py", line 26, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in __call__
    raise exc
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in __call__
    raise e
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 341, in handle
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 82, in app
    await func(session)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\routing.py", line 289, in app
    await dependant.call(**values)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\gradio\routes.py", line 604, in join_queue
    session_info = await asyncio.wait_for(
  File "C:\Users\PC2022\AppData\Local\Programs\Python\Python310\lib\asyncio\tasks.py", line 445, in wait_for
    return fut.result()
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 133, in receive_json
    self._raise_on_disconnect(message)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 105, in _raise_on_disconnect
    raise WebSocketDisconnect(message["code"])
starlette.websockets.WebSocketDisconnect: 1001
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\protocols\websockets\websockets_impl.py", line 250, in run_asgi
    result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\errors.py", line 149, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\cors.py", line 76, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\gzip.py", line 26, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in __call__
    raise exc
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in __call__
    raise e
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 341, in handle
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 82, in app
    await func(session)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\routing.py", line 289, in app
    await dependant.call(**values)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\gradio\routes.py", line 604, in join_queue
    session_info = await asyncio.wait_for(
  File "C:\Users\PC2022\AppData\Local\Programs\Python\Python310\lib\asyncio\tasks.py", line 445, in wait_for
    return fut.result()
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 133, in receive_json
    self._raise_on_disconnect(message)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 105, in _raise_on_disconnect
    raise WebSocketDisconnect(message["code"])
starlette.websockets.WebSocketDisconnect: 1001
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\protocols\websockets\websockets_impl.py", line 250, in run_asgi
    result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\errors.py", line 149, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\cors.py", line 76, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\gzip.py", line 26, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in __call__
    raise exc
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in __call__
    raise e
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 341, in handle
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 82, in app
    await func(session)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\routing.py", line 289, in app
    await dependant.call(**values)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\gradio\routes.py", line 604, in join_queue
    session_info = await asyncio.wait_for(
  File "C:\Users\PC2022\AppData\Local\Programs\Python\Python310\lib\asyncio\tasks.py", line 445, in wait_for
    return fut.result()
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 133, in receive_json
    self._raise_on_disconnect(message)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 105, in _raise_on_disconnect
    raise WebSocketDisconnect(message["code"])
starlette.websockets.WebSocketDisconnect: 1001
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\protocols\websockets\websockets_impl.py", line 250, in run_asgi
    result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\errors.py", line 149, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\cors.py", line 76, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\gzip.py", line 26, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in __call__
    raise exc
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in __call__
    raise e
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 341, in handle
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 82, in app
    await func(session)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\routing.py", line 289, in app
    await dependant.call(**values)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\gradio\routes.py", line 604, in join_queue
    session_info = await asyncio.wait_for(
  File "C:\Users\PC2022\AppData\Local\Programs\Python\Python310\lib\asyncio\tasks.py", line 445, in wait_for
    return fut.result()
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 133, in receive_json
    self._raise_on_disconnect(message)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 105, in _raise_on_disconnect
    raise WebSocketDisconnect(message["code"])
starlette.websockets.WebSocketDisconnect: 1001
ERROR:    Exception in ASGI application
Traceback (most recent call last):
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\protocols\websockets\websockets_impl.py", line 250, in run_asgi
    result = await self.app(self.scope, self.asgi_receive, self.asgi_send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\uvicorn\middleware\proxy_headers.py", line 84, in __call__
    return await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\applications.py", line 273, in __call__
    await super().__call__(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\applications.py", line 122, in __call__
    await self.middleware_stack(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\errors.py", line 149, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\cors.py", line 76, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\gzip.py", line 26, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 79, in __call__
    raise exc
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\middleware\exceptions.py", line 68, in __call__
    await self.app(scope, receive, sender)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 21, in __call__
    raise e
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\middleware\asyncexitstack.py", line 18, in __call__
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 718, in __call__
    await route.handle(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 341, in handle
    await self.app(scope, receive, send)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\routing.py", line 82, in app
    await func(session)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\fastapi\routing.py", line 289, in app
    await dependant.call(**values)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\gradio\routes.py", line 604, in join_queue
    session_info = await asyncio.wait_for(
  File "C:\Users\PC2022\AppData\Local\Programs\Python\Python310\lib\asyncio\tasks.py", line 445, in wait_for
    return fut.result()
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 133, in receive_json
    self._raise_on_disconnect(message)
  File "D:\ai\sd-webui-1-6\venv\lib\site-packages\starlette\websockets.py", line 105, in _raise_on_disconnect
    raise WebSocketDisconnect(message["code"])
starlette.websockets.WebSocketDisconnect: 1001

ENTPRESTIGIOUS avatar Jan 13 '24 06:01 ENTPRESTIGIOUS