From a3ad11116aec3a70aa703edf320e455e5dee9ea7 Mon Sep 17 00:00:00 2001 From: Jason Hoku Date: Tue, 12 May 2026 12:40:16 -0700 Subject: [PATCH] =?UTF-8?q?fix:=20VAE=20=E2=80=94=20honor=20bypass=20state?= =?UTF-8?q?=20+=20omit=20"vae"=20key=20when=20nothing=20selected?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two bugs in state_to_configs_json's VAE emission: 1. Bypass (unchecked) VAEs were still sent through — vae_bypass_states was never consulted in the filter. Now filtered alongside the None/empty check. 2. When no VAE remained (empty list, all bypassed, or only "None"), the config emitted "vae": "None" — the orchestrator interpreted that as a model filename and threw "vae model with filename 'None' not found". Now the "vae" key is OMITTED entirely so the generator falls back to its default behavior (no per-config VAE override), matching the pattern already used for text_encoders/clip_type/etc. Co-Authored-By: Claude Opus 4.7 (1M context) --- config_builder_node.py | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/config_builder_node.py b/config_builder_node.py index 04cda6e..cda86b6 100644 --- a/config_builder_node.py +++ b/config_builder_node.py @@ -633,13 +633,20 @@ class UltimateConfigBuilder: full_run_seed = config_array.get("full_run_seed", 0) config["full_run_seed"] = int(full_run_seed) if full_run_seed else 0 - # Process VAEs — always include (default "None" if unset) + # Process VAEs — filter out bypassed (unchecked) entries AND any + # empty / "None" placeholders. If nothing remains, OMIT the "vae" + # key entirely so the orchestrator falls back to the default + # behavior (no per-config VAE override). Emitting "vae": "None" + # made the generator try to load a model file literally named + # "None", which fails. vaes_raw = config_array.get("vaes", ["None"]) - vae_strings = [str(v) for v in vaes_raw if v and v != "None"] + vae_bypass_states = config_array.get("vae_bypass_states", {}) or {} + vae_strings = [ + str(v) for v in vaes_raw + if v and v != "None" and not vae_bypass_states.get(str(v), False) + ] if vae_strings: config["vae"] = vae_strings if len(vae_strings) > 1 else vae_strings[0] - else: - config["vae"] = "None" # Always include model_type and related fields config["model_type"] = model_type