Commit 4b6eb807 authored by AUTOMATIC1111's avatar AUTOMATIC1111 Committed by GitHub

Merge pull request #14407 from AUTOMATIC1111/prevent-crash-due-to-Script-__init__-exception

prevent crash due to Script __init__ exception
parents 908fb4ea edfae95d
......@@ -566,7 +566,12 @@ class ScriptRunner:
auto_processing_scripts = scripts_auto_postprocessing.create_auto_preprocessing_script_data()
for script_data in auto_processing_scripts + scripts_data:
try:
script = script_data.script_class()
except Exception:
errors.report(f"Error # failed to initialize Script {script_data.module}: ", exc_info=True)
continue
script.filename = script_data.path
script.is_txt2img = not is_img2img
script.is_img2img = is_img2img
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment