Hello
I created an automation using the GUI that seemed to need a or condition in the actions section. I tried adding that in the file editor. The file editor says OK to the formatting but i’m getting this in the log:
Logger: homeassistant.config Source: config.py:454
First occurred: 15:19:27 (3 occurrences)
Last logged: 15:24:45 Invalid config for [automation]: Expected a dictionary @ data['action'][0]['conditions'][8]. Got None Expected a dictionary @ data['action'][0]['conditions'][9]. Got None Unexpected value for condition: 'None'. Expected and, device, not, numeric_state, or, state, sun, template, time, trigger, zone @ data['action'][0]['conditions'][1]. Got None Unexpected value for condition: 'None'. Expected and, device, not, numeric_state, or, state, sun, template, time, trigger, zone @ data['action'][0]['conditions'][3]. Got None Unexpected value for condition: 'None'. Expected and, device, not, numeric_state, or, state, sun, template, time, trigger, zone @ data['action'][0]['conditions'][5]. Got None Unexpected value for condition: 'None'. Expected and, device, not, numeric_state, or, state, sun, template, time, trigger, zone @ data['action'][0]['conditions'][7]. Got None. (See /config/configuration.yaml, line 9).
My automation looks like this:
## lysrutine
- id: '1644736228461'
alias: Night Mode off - Lysrutine
description: ''
trigger:
- platform: state
entity_id: input_boolean.godnat
from: 'on'
to: 'off'
- platform: state
entity_id: group.family
from: not_home
to: home
- type: motion
platform: device
device_id: 51b5aa9704b060f0587e49f5f929a27b
entity_id: binary_sensor.bryggers_motion_01_occupancy
domain: binary_sensor
- type: motion
platform: device
device_id: cfdd0b95cfc640fded81662d57986268
entity_id: binary_sensor.gang_motion_01_occupancy
domain: binary_sensor
- type: motion
platform: device
device_id: b7393818d3b1c99a49c951c77da86718
entity_id: binary_sensor.koekken_motion_01_occupancy
domain: binary_sensor
condition:
- condition: state
entity_id: group.family
state: home
- condition: state
entity_id: input_boolean.godnat
state: 'off'
- condition: state
entity_id: input_boolean.bypass_light_routine
state: 'off'
action:
- condition: or
conditions:
- condition: time
after: 05:00
before: 07:54
- scene: scene.morgenlys ## <-- what i think is the problematic part
- condition: time
after: 07:55
before: 09:15
- scene: scene.formiddagslys
- condition: time
after: 09:16
before: '19:30'
- scene: scene.dagslys
- condition: time
after: '19:31'
before: 03:00
- service: light.turn_on
data:
transition: 300
kelvin: 2200
brightness_pct: 55
target:
entity_id:
- light.stue_lights_zgrp
- light.koekken_lights_zgrp
mode: single
I tried added the indents i could think of to the actions section, but i cant figure it out.
Help is appreciated. Thank you.