From f316280ad3634a2343b086a6de0bfcd473e18599 Mon Sep 17 00:00:00 2001 From: AUTOMATIC <16777216c@gmail.com> Date: Fri, 4 Nov 2022 16:48:40 +0300 Subject: [PATCH] fix the error that prevents from setting some options --- modules/shared.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/modules/shared.py b/modules/shared.py index a9e28b9c4..962115f61 100644 --- a/modules/shared.py +++ b/modules/shared.py @@ -406,7 +406,8 @@ class Options: if key in self.data or key in self.data_labels: assert not cmd_opts.freeze_settings, "changing settings is disabled" - comp_args = opts.data_labels[key].component_args + info = opts.data_labels.get(key, None) + comp_args = info.component_args if info else None if isinstance(comp_args, dict) and comp_args.get('visible', True) is False: raise RuntimeError(f"not possible to set {key} because it is restricted")