diff --git a/hordelib/horde.py b/hordelib/horde.py index d0732958..404dea7e 100644 --- a/hordelib/horde.py +++ b/hordelib/horde.py @@ -214,7 +214,7 @@ class HordeLib: } # pipeline parameter <- hordelib payload parameter mapping - PAYLOAD_TO_PIPELINE_PARAMETER_MAPPING: dict[str, str | FunctionType] = { # FIXME + PAYLOAD_TO_PIPELINE_PARAMETER_MAPPING: dict[str, str | Callable] = { # FIXME "sampler.sampler_name": "sampler_name", "sampler.cfg": "cfg_scale", "sampler.denoise": "denoising_strength", @@ -820,6 +820,9 @@ def _final_pipeline_adjustments(self, payload, pipeline_data) -> tuple[dict, lis # values for steps on things like stable cascade if isinstance(key, FunctionType): pipeline_params[newkey] = key(payload) + elif not isinstance(key, str): + logger.error(f"Invalid key {key}") + raise RuntimeError(f"Invalid key {key}") elif "*" in key: key, multiplier = key.split("*", 1) elif key in payload: