vormsty
(Vormsty)
1
Hello,
I would like to use an input_datetime for a delay, but I don’t find the right syntax:
action:
- delay: {{states(‘input_datetime.coldperiodeduration’)}}
I try it in developpement tool and It show the right value.
in automation it is an error:
Error loading /config/configuration.yaml: invalid key: “OrderedDict([(“states(‘input_datetime.coldperiodeduration’)”, None)])”
in “/config/automations/coldperiod.yaml”, line 36, column 0
Can anybody correct me please ?
Best regards
Thierry
tom_l
2
You need to put single line templates in quotes:
delay: "{{states('input_datetime.coldperiodeduration')}}"
You also need to remember to format your pasted config correctly in your forum topics.
123
(Taras)
3
It appears we simultaneously replied to a question that was posted in multiple places.
tom_l
4
Oh good grief.
@vormsty don’t cross post like that either. One topic per issue is sufficient.
vormsty
(Vormsty)
5
Ok, sorry I was very disappointed.
Thanks for your response