Automations not turning back on with automation.turn_on

Hi,

I have several automations that alert me of intruders via PIR sensors. To reduce false alarms I have added a 10 minute delay. I achieved this by turning off the automation then turning it back on, like this:


- alias: Dakota Left Side of Unit 1
  initial_state: true
  trigger:
  - entity_id: sensor.left_unit_1_sensor
    platform: state
    to: 'ON'
  action:
  - service: notify.mobile_app_bens_iphone
    data:
      title: "Yard Alert"
      message: "Motion LEFT side of Unit 1"
  - service: automation.turn_off
    entity_id: automation.dakota_left_side_of_unit_1
  - delay: 00:10:00
  - service: automation.turn_on
    entity_id: automation.dakota_left_side_of_unit_1

This has worked fine for years, but has recently stopped turning the automations back on once they’ve been triggered once. I have tried adding initial_state: true, but this does not help.

Does anyone have any ideas. I can’t see anything in the logs.

Thanks,
Ben