I am trying to copy and paste part of a config.yaml file into a new file. This is the clip.
#TempDiff
######
- platform: template
sensors:
temperature_difference:
friendly_name: "Temperature Difference"
unit_of_measurement: '°C'
value_template: >
{{ ( states('sensor.lumi_lumi_weather_temperature')|float(0) - states('sensor.lumi_lumi_weather_b083df07_temperature')|float(0) )|round(2) }}
When I paste it in I get these errors
#TempDiff
######
- platform: template bad indentation of a mapping entry
sensors:
temperature_difference: can not read a block mapping entry; a multiline key may not be an implicit key
friendly_name: "Temperature Difference"
unit_of_measurement: '°C'
value_template: >
{{ ( states('sensor.lumi_lumi_weather_temperature')|float(0) - states('sensor.lumi_lumi_weather_b083df07_temperature')|float(0) )|round(2) }}
What am I doing wrong here?