[GH-ISSUE #203] Error loading script: model_keyword_support.py and error loading script: tag_autocomplete_helper.py #145

Closed
opened 2026-10-30 21:20:03 +00:00 by bsakaguchi · 3 comments
Owner

Originally created by @Some1StoleMyName on GitHub (Jul 22, 2023).
Original GitHub issue: https://github.com/DominikDoom/a1111-sd-webui-tagcomplete/issues/203

im getting this error

*** Error loading script: model_keyword_support.py
Traceback (most recent call last):
File "D:\stable-diffusion-webui\modules\scripts.py", line 274, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "D:\stable-diffusion-webui\modules\script_loading.py", line 10, in load_module
module_spec.loader.exec_module(module)
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\model_keyword_support.py", line 10, in
known_hashes_file.touch()
File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 1168, in touch
self._accessor.touch(self, mode, exist_ok)
File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 331, in touch
fd = os.open(path, flags, mode)
FileNotFoundError: [Errno 2] No such file or directory: 'D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\tags\temp\known_lora_hashes.txt'


*** Error loading script: tag_autocomplete_helper.py
Traceback (most recent call last):
File "D:\stable-diffusion-webui\modules\scripts.py", line 274, in load_scripts
script_module = script_loading.load_module(scriptfile.path)
File "D:\stable-diffusion-webui\modules\script_loading.py", line 10, in load_module
module_spec.loader.exec_module(module)
File "", line 883, in exec_module
File "", line 241, in _call_with_frames_removed
File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\tag_autocomplete_helper.py", line 11, in
from scripts.model_keyword_support import (get_lora_simple_hash,
File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\model_keyword_support.py", line 10, in
known_hashes_file.touch()
File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 1168, in touch
self._accessor.touch(self, mode, exist_ok)
File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 331, in touch
fd = os.open(path, flags, mode)
FileNotFoundError: [Errno 2] No such file or directory: 'D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\tags\temp\known_lora_hashes.txt'

Originally created by @Some1StoleMyName on GitHub (Jul 22, 2023). Original GitHub issue: https://github.com/DominikDoom/a1111-sd-webui-tagcomplete/issues/203 im getting this error *** Error loading script: model_keyword_support.py Traceback (most recent call last): File "D:\stable-diffusion-webui\modules\scripts.py", line 274, in load_scripts script_module = script_loading.load_module(scriptfile.path) File "D:\stable-diffusion-webui\modules\script_loading.py", line 10, in load_module module_spec.loader.exec_module(module) File "<frozen importlib._bootstrap_external>", line 883, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\model_keyword_support.py", line 10, in <module> known_hashes_file.touch() File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 1168, in touch self._accessor.touch(self, mode, exist_ok) File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 331, in touch fd = os.open(path, flags, mode) FileNotFoundError: [Errno 2] No such file or directory: 'D:\\stable-diffusion-webui\\extensions\\a1111-sd-webui-tagcomplete\\tags\\temp\\known_lora_hashes.txt' --- *** Error loading script: tag_autocomplete_helper.py Traceback (most recent call last): File "D:\stable-diffusion-webui\modules\scripts.py", line 274, in load_scripts script_module = script_loading.load_module(scriptfile.path) File "D:\stable-diffusion-webui\modules\script_loading.py", line 10, in load_module module_spec.loader.exec_module(module) File "<frozen importlib._bootstrap_external>", line 883, in exec_module File "<frozen importlib._bootstrap>", line 241, in _call_with_frames_removed File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\tag_autocomplete_helper.py", line 11, in <module> from scripts.model_keyword_support import (get_lora_simple_hash, File "D:\stable-diffusion-webui\extensions\a1111-sd-webui-tagcomplete\scripts\model_keyword_support.py", line 10, in <module> known_hashes_file.touch() File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 1168, in touch self._accessor.touch(self, mode, exist_ok) File "C:\Users\username\AppData\Local\Programs\Python\Python310\lib\pathlib.py", line 331, in touch fd = os.open(path, flags, mode) FileNotFoundError: [Errno 2] No such file or directory: 'D:\\stable-diffusion-webui\\extensions\\a1111-sd-webui-tagcomplete\\tags\\temp\\known_lora_hashes.txt'
Author
Owner

@changaolee commented on GitHub (Jul 22, 2023):

same error

<!-- gh-comment-id:1646641550 --> @changaolee commented on GitHub (Jul 22, 2023): same error
Author
Owner

@Therises commented on GitHub (Jul 22, 2023):

Same here.

<!-- gh-comment-id:1646644136 --> @Therises commented on GitHub (Jul 22, 2023): Same here.
Author
Owner

@DominikDoom commented on GitHub (Jul 22, 2023):

This was due to not checking if the temp folder itself was already created at this point.
I only tested it with an existing installation and the files itself being deleted, not the whole folder, so I didn't catch it. Sorry for the inconvenience.

<!-- gh-comment-id:1646649291 --> @DominikDoom commented on GitHub (Jul 22, 2023): This was due to not checking if the temp folder itself was already created at this point. I only tested it with an existing installation and the files itself being deleted, not the whole folder, so I didn't catch it. Sorry for the inconvenience.
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#145
No description provided.