I have this automation for opening a cover at a certain random position, to be triggered at a certain time:
- id: '1628609350131'
alias: Simulazione Presenza Mattina
description: ''
trigger:
- platform: time
at: ’18:24:00’
condition: []
action:
- service: cover.set_cover_position
entity_id: cover.camera
position: "{{ ''{:02}''.format(range(0, 10) | random | int) }}"
mode: single
The problem is the automation is not triggered at the chosen time.
The automation works correctly if I click on Execute, bypassing the time trigger.
The time trigger itself works correctly if I set a fixed value in “position”.
Any hints?