From aeb9d9993033ce249452778c8df9b53bec99867e Mon Sep 17 00:00:00 2001 From: John Ogle Date: Sun, 21 Dec 2025 18:10:46 -0800 Subject: [PATCH] Fix YAML block scalar causing template line-wrapping in blueprints Replace block scalar (>-) with regular quoted strings for settings_entity templates. The block scalar was causing Home Assistant to wrap lines in the middle of the replace() function call, breaking the template parsing. This fixes: - LED color not updating in mode cycling automation - Mode settings not being applied in apply mode automation The templates now stay on a single line and parse correctly. --- blueprints/automation/apply_lighting_mode.yaml | 3 +-- blueprints/automation/inovelli_mode_cycling.yaml | 3 +-- 2 files changed, 2 insertions(+), 4 deletions(-) diff --git a/blueprints/automation/apply_lighting_mode.yaml b/blueprints/automation/apply_lighting_mode.yaml index 642f683..5aabd55 100644 --- a/blueprints/automation/apply_lighting_mode.yaml +++ b/blueprints/automation/apply_lighting_mode.yaml @@ -40,8 +40,7 @@ variables: al_switch: !input adaptive_lighting_switch led_entity: !input led_color_entity mode: "{{ states(mode_select) }}" - settings_entity: >- - input_text.adaptive_lighting_settings_{{ mode | lower | replace(' ', '_') }} + settings_entity: "input_text.adaptive_lighting_settings_{{ mode | lower | replace(' ', '_') }}" settings: "{{ states(settings_entity) | from_json }}" behavior: "{{ settings.behavior | default('adaptive_lighting') }}" manual_control: "{{ settings.manual_control | default(false) }}" diff --git a/blueprints/automation/inovelli_mode_cycling.yaml b/blueprints/automation/inovelli_mode_cycling.yaml index a79a1a1..b9d7134 100644 --- a/blueprints/automation/inovelli_mode_cycling.yaml +++ b/blueprints/automation/inovelli_mode_cycling.yaml @@ -72,8 +72,7 @@ action: current_index: "{{ available_modes.index(current_mode) }}" next_index: "{{ (current_index + 1) % (available_modes | length) }}" next_mode: "{{ available_modes[next_index] }}" - next_mode_settings_entity: >- - input_text.adaptive_lighting_settings_{{ next_mode | lower | replace(' ', '_') }} + next_mode_settings_entity: "input_text.adaptive_lighting_settings_{{ next_mode | lower | replace(' ', '_') }}" next_mode_settings: "{{ states(next_mode_settings_entity) | from_json }}" next_color: "{{ next_mode_settings.led_color | default(170) }}"