Quantcast
Channel: Configuration - Home Assistant Community
Viewing all articles
Browse latest Browse all 107652

Template Not Creating a Sensor

$
0
0

I am working with a very simple template, that looks like this:

template:
  - sensor:
      - name: "nextsunrise"
        friendly_name: "Next Sunrise"
        value_template: >
          {{ as_timestamp(states.sun.sun.attributes.next_rising) | timestamp_custom(' %I:%M %p') | replace(" 0", "") }}
        icon_template: mdi:weather-sunset-up

The entity sun.sun does exist, and the attribute next_rising also exists, with a valid value. When I put the template into the the Template Editor, the correct value is returned. HOWEVER - the sensor “sensor.nextsunrise” does not get created. I cannot find it using STATES, nor can I find it when trying to use that value in a dashboard. I’ve been looking through the documentation, and I cannot seem to figure out where I’m screwing this up. Help?

Sean

6 posts - 2 participants

Read full topic


Viewing all articles
Browse latest Browse all 107652

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>