[GH-ISSUE #145] anyone have this issue? #104

Closed
opened 2026-10-30 21:19:19 +00:00 by bsakaguchi · 5 comments
Owner

Originally created by @basedholychad on GitHub (Mar 26, 2023).
Original GitHub issue: https://github.com/DominikDoom/a1111-sd-webui-tagcomplete/issues/145

Originally created by @basedholychad on GitHub (Mar 26, 2023). Original GitHub issue: https://github.com/DominikDoom/a1111-sd-webui-tagcomplete/issues/145
Author
Owner

@basedholychad commented on GitHub (Mar 26, 2023):

Additional Network extension not installed, Only hijack built-in lora
LoCon Extension hijack built-in lora successfully
Error loading script: tag_autocomplete_helper.py
Traceback (most recent call last):
File "/content/stable-diffusion-webui/modules/scripts.py", line 248, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "/content/stable-diffusion-webui/modules/script_loading.py", line 11, in load_module
module_spec.loader.exec_module(module)
File "", line 850, in exec_module
File "", line 228, in _call_with_frames_removed
File "/content/stable-diffusion-webui/extensions/a1111-sd-webui-tagcomplete/scripts/tag_autocomplete_helper.py", line 7, in
from modules.paths import script_path, extensions_dir
ImportError: cannot import name 'extensions_dir' from 'modules.paths' (/content/stable-diffusion-webui/modules/paths.py)

<!-- gh-comment-id:1484096060 --> @basedholychad commented on GitHub (Mar 26, 2023): Additional Network extension not installed, Only hijack built-in lora LoCon Extension hijack built-in lora successfully Error loading script: tag_autocomplete_helper.py Traceback (most recent call last): File "/content/stable-diffusion-webui/modules/scripts.py", line 248, in load_scripts script_module = script_loading.load_module(scriptfile.path) File "/content/stable-diffusion-webui/modules/script_loading.py", line 11, in load_module module_spec.loader.exec_module(module) File "<frozen importlib._bootstrap_external>", line 850, in exec_module File "<frozen importlib._bootstrap>", line 228, in _call_with_frames_removed File "/content/stable-diffusion-webui/extensions/a1111-sd-webui-tagcomplete/scripts/tag_autocomplete_helper.py", line 7, in <module> from modules.paths import script_path, extensions_dir ImportError: cannot import name 'extensions_dir' from 'modules.paths' (/content/stable-diffusion-webui/modules/paths.py)
Author
Owner

@basedholychad commented on GitHub (Mar 26, 2023):

sorry i'm new here and i'm very amateur idk if only i meet this issue i'm using colab and this only happens today

<!-- gh-comment-id:1484096396 --> @basedholychad commented on GitHub (Mar 26, 2023): sorry i'm new here and i'm very amateur idk if only i meet this issue i'm using colab and this only happens today
Author
Owner

@basedholychad commented on GitHub (Mar 26, 2023):

ERROR: Exception in ASGI application
Traceback (most recent call last):
File "/usr/local/lib/python3.9/dist-packages/starlette/responses.py", line 331, in call
stat_result = await anyio.to_thread.run_sync(os.stat, self.path)
File "/usr/local/lib/python3.9/dist-packages/anyio/to_thread.py", line 31, in run_sync
return await get_asynclib().run_sync_in_worker_thread(
File "/usr/local/lib/python3.9/dist-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread
return await future
File "/usr/local/lib/python3.9/dist-packages/anyio/_backends/_asyncio.py", line 867, in run
result = context.run(func, *args)
FileNotFoundError: [Errno 2] No such file or directory: '/content/stable-diffusion-webui/tmp/tagAutocompletePath.txt'

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/usr/local/lib/python3.9/dist-packages/uvicorn/protocols/http/h11_impl.py", line 429, in run_asgi
result = await app( # type: ignore[func-returns-value]
File "/usr/local/lib/python3.9/dist-packages/uvicorn/middleware/proxy_headers.py", line 78, in call
return await self.app(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/fastapi/applications.py", line 270, in call
await super().call(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/applications.py", line 124, in call
await self.middleware_stack(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/errors.py", line 184, in call
raise exc
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/errors.py", line 162, in call
await self.app(scope, receive, _send)
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/gzip.py", line 24, in call
await responder(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/gzip.py", line 44, in call
await self.app(scope, receive, self.send_with_gzip)
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/exceptions.py", line 79, in call
raise exc
File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/exceptions.py", line 68, in call
await self.app(scope, receive, sender)
File "/usr/local/lib/python3.9/dist-packages/fastapi/middleware/asyncexitstack.py", line 21, in call
raise e
File "/usr/local/lib/python3.9/dist-packages/fastapi/middleware/asyncexitstack.py", line 18, in call
await self.app(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 706, in call
await route.handle(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 276, in handle
await self.app(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 69, in app
await response(scope, receive, send)
File "/usr/local/lib/python3.9/dist-packages/starlette/responses.py", line 334, in call
raise RuntimeError(f"File at path {self.path} does not exist.")
RuntimeError: File at path /content/stable-diffusion-webui/tmp/tagAutocompletePath.txt does not exist.

<!-- gh-comment-id:1484098393 --> @basedholychad commented on GitHub (Mar 26, 2023): ERROR: Exception in ASGI application Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/starlette/responses.py", line 331, in __call__ stat_result = await anyio.to_thread.run_sync(os.stat, self.path) File "/usr/local/lib/python3.9/dist-packages/anyio/to_thread.py", line 31, in run_sync return await get_asynclib().run_sync_in_worker_thread( File "/usr/local/lib/python3.9/dist-packages/anyio/_backends/_asyncio.py", line 937, in run_sync_in_worker_thread return await future File "/usr/local/lib/python3.9/dist-packages/anyio/_backends/_asyncio.py", line 867, in run result = context.run(func, *args) FileNotFoundError: [Errno 2] No such file or directory: '/content/stable-diffusion-webui/tmp/tagAutocompletePath.txt' During handling of the above exception, another exception occurred: Traceback (most recent call last): File "/usr/local/lib/python3.9/dist-packages/uvicorn/protocols/http/h11_impl.py", line 429, in run_asgi result = await app( # type: ignore[func-returns-value] File "/usr/local/lib/python3.9/dist-packages/uvicorn/middleware/proxy_headers.py", line 78, in __call__ return await self.app(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/fastapi/applications.py", line 270, in __call__ await super().__call__(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/applications.py", line 124, in __call__ await self.middleware_stack(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/errors.py", line 184, in __call__ raise exc File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/errors.py", line 162, in __call__ await self.app(scope, receive, _send) File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/gzip.py", line 24, in __call__ await responder(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/gzip.py", line 44, in __call__ await self.app(scope, receive, self.send_with_gzip) File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/exceptions.py", line 79, in __call__ raise exc File "/usr/local/lib/python3.9/dist-packages/starlette/middleware/exceptions.py", line 68, in __call__ await self.app(scope, receive, sender) File "/usr/local/lib/python3.9/dist-packages/fastapi/middleware/asyncexitstack.py", line 21, in __call__ raise e File "/usr/local/lib/python3.9/dist-packages/fastapi/middleware/asyncexitstack.py", line 18, in __call__ await self.app(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 706, in __call__ await route.handle(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 276, in handle await self.app(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/routing.py", line 69, in app await response(scope, receive, send) File "/usr/local/lib/python3.9/dist-packages/starlette/responses.py", line 334, in __call__ raise RuntimeError(f"File at path {self.path} does not exist.") RuntimeError: File at path /content/stable-diffusion-webui/tmp/tagAutocompletePath.txt does not exist.
Author
Owner

@Zhroyn commented on GitHub (Mar 26, 2023):

I encounter the same problem, and get reminded by this reported error:
ImportError: cannot import name 'extensions_dir' from 'modules.paths' (D:\repositories\stable-diffusion-webui\modules\paths.py)
It tell me that there may be some error in the file pointed out by this report.

In my case, I open the file in the path "D:\repositories\stable-diffusion-webui\modules\paths.py", and as expected, there is no "extension_dir" in this file, so what we need to do is to add this variable.
Then under the thirteenth line "models_path = os.path.join(data_path, "models")", which is my case, I append a line :
extensions_dir = os.path.join(data_path, "extensions")

Then I reload the webui, and find everything ok this time.

<!-- gh-comment-id:1484106521 --> @Zhroyn commented on GitHub (Mar 26, 2023): I encounter the same problem, and get reminded by this reported error: ImportError: cannot import name 'extensions_dir' from 'modules.paths' (D:\repositories\stable-diffusion-webui\modules\paths.py) It tell me that there may be some error in the file pointed out by this report. In my case, I open the file in the path "D:\repositories\stable-diffusion-webui\modules\paths.py", and as expected, there is no "extension_dir" in this file, so what we need to do is to add this variable. Then under the thirteenth line "models_path = os.path.join(data_path, "models")", which is my case, I append a line : extensions_dir = os.path.join(data_path, "extensions") Then I reload the webui, and find everything ok this time.
Author
Owner

@DominikDoom commented on GitHub (Mar 26, 2023):

If you update your webui, the current version has these path variables built in.
I also added a fallback for it now though, so it should also work with older versions that don't have this path yet.

<!-- gh-comment-id:1484114434 --> @DominikDoom commented on GitHub (Mar 26, 2023): If you update your webui, the current version has these path variables built in. I also added a fallback for it now though, so it should also work with older versions that don't have this path yet.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
DominikDoom/a1111-sd-webui-tagcomplete#104
No description provided.