I’m trying to use a template condition for a conditional card but am not having success. The docs say that this YAML should work as the conditions list:
conditions: "{{ (state_attr('device_tracker.iphone', 'battery_level')|int) > 50 }}"
but I get an error with an even simpler setup:
If I fall back to another example from the docs:
conditions:
- "{{ (state_attr('device_tracker.iphone', 'battery_level')|int) > 50 }}"
I get a different error:
Using the full syntax throws a third distinct error:
Did I get the syntax wrong in all three cases or is something else amiss?