Automations not triggered anymore

Since a few days my automations won’t trigger anymore, that was on 0.42.3. I just upgraded to 0.43.0 and my automations still won’t trigger. Example:

alias: Lamp wasruimte aan
  trigger:
    platform: state
    entity_id: binary_sensor.door_window_sensor_158d0001184e9a
    to: 'on'
  action:
    service: light.turn_on
    entity_id: light.wasruimte
    data:
      transition: 2
      brightness: 180

My config validates and I see the sensor going from off to on.

Same goes for simple automations like “turn the lights off at 23:00”. What happened ?

Hi @piotr, since 0.42 you have to set an initial state in your automations.
initial_state: True
Or you change the states of your automation in Developer Tools / States manualy to on.
Then HA restores them on restart.

2 Likes

Thanks for the info VDRainer!

This would seem like a good piece of information to add to the automations documentation page. I’ll go see if I can edit it…

I have no idea if my edit worked or will be accepted, but I did some Github voodoo that seemed like it created the necessary forks/pull requests to get the change to the right people.

-Chad

I’m still having this issue even after adding initial_state: True to each of my automations.

I see the automation being triggered in the logs and I can trigger them manually but nothing happens.

That sounds like a different issue. initial_state should show the automation as being “active” after restarting the HA process. Automations not executing/completing/working correctly don’t seem like they’d be related to that. When I’m troubleshooting automations, I’ll start with a simple skeleton like turning on a light at a specific time. If that works, then I’ll add in the complexity in my non-working example until I hit the point where it doesn’t work anymore and go from there looking at the docs and searching the forums for that specific condition/trigger/script to see what I might be missing.

Are any of your automations still working? Can you scale down to a very simple one, like turning a light on when a door/window is opened to see if that works?