From 66d1a22c733b04c38d89a128a7eeacd8e142e629 Mon Sep 17 00:00:00 2001 From: oobabooga <112222186+oobabooga@users.noreply.github.com> Date: Fri, 3 Apr 2026 05:56:36 -0700 Subject: [PATCH] Fix crash when no model is selected (None passed to resolve_model_path) --- modules/utils.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/modules/utils.py b/modules/utils.py index b01953ee..c4acf714 100644 --- a/modules/utils.py +++ b/modules/utils.py @@ -105,6 +105,9 @@ def resolve_model_path(model_name_or_path, image_model=False): before the default models directory. """ + if model_name_or_path is None: + raise FileNotFoundError("No model specified.") + path_candidate = Path(model_name_or_path) if path_candidate.exists(): return path_candidate