From 027648e398032ec347def3eb24bf0e9b5c4908e5 Mon Sep 17 00:00:00 2001 From: Benjamin Berman Date: Mon, 11 Aug 2025 12:08:25 -0700 Subject: [PATCH] Fix model name bug with sd1 --- comfy/sd1_clip.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/comfy/sd1_clip.py b/comfy/sd1_clip.py index 402954bb6..90742afde 100644 --- a/comfy/sd1_clip.py +++ b/comfy/sd1_clip.py @@ -122,7 +122,8 @@ class SDClipModel(torch.nn.Module, ClipTokenWeightEncoder): model_options = {**model_options, "model_name": "clip_l"} if "model_name" in model_options and "clip" not in model_options["model_name"].lower() and textmodel_json_config is None: - logger.warning(f"Text encoder {model_options["model_name"]} provided a None textmodel_json_config, when it should have been an empty dict") + _model_name = model_options['model_name'] + logger.warning(f"Text encoder {_model_name} provided a None textmodel_json_config, when it should have been an empty dict") textmodel_json_config = {} config = get_path_as_dict(textmodel_json_config, "sd1_clip_config.json", package=__package__)