I have an auromation to switch off a charge point when a couple of conditions are met. However, when the automation is saved it changes subsequent chevrons, after the template_value to “|” any reason for this? please see automation below: especially the second line with value_template. I believe its causing the automation to fail, although not with any errors. It does this with other automations.
Ill just add that im using the automations editor with the “edit yaml” option.
alias: Auto Van Charge Off
description: Turn Van Charging off
trigger:
- platform: template
value_template: >
{{ (states('sensor.sofar_gen_watts') | float(0) +
states('sensor.sofar2_gen_watts') | float(0)) <= 6.8}}
- platform: template
value_template: |
{{ states('sensor.sofar_battery_soc') | int(0) <= 95 }}
condition: []
action:
- service: homeassistant.turn_off
entity_id: switch.van_switch
mode: single
Thanks for the reply as long as its a valid character thats OK. The failure must be somethuing else I have done. Whats the reason behind the editor changing the chevron when the automation is saved?
That’s what the developers of the Automation Editor decided to use as the default line-continuation character. There are several other YAML and Jinja2 conventions that are used to format scripts and automations.
What is the exact nature of the failure?
If it fails to trigger, review the explanation I posted above.