dt1000
(Dan Taylor)
1
Hi there. I am currently writing a custom template to control my Nest thermostat.
The code…
{{state_attr('climate.hallway', 'current_temperature')}}
…returns the current temperature, as expected. However, if I try to get the target temperature with…
{{state_attr('climate.hallway', 'target_temperature')}}
…it returns nothing!
I did a little testing - all the other attributes return fine, and none of my other climate devices return a Target Temperature either.
According to this documentation I have the correct attribute name… any clues as to what I might be doing wrong?
Thanks in advance for your help!
Dan
I think the target temperature ends up in ‘temperature’.
1 Like
tom_l
3
That is correct.
Look in Developer Tools → States, right hand column next to your climate entity.
dt1000
(Dan Taylor)
4
Thanks! That is really frustrating - is there any way to get the documentation fixed? ![:rofl: :rofl:](https://community.home-assistant.io/images/emoji/twitter/rofl.png?v=12)
tom_l
5
You linked to the developer docs. That is not what you should be using, this is:
dt1000
(Dan Taylor)
6
Ah… good to know. The dev docs were the first thing that Google spat out when I started investigating. Pesky Google. ![:sunglasses: :sunglasses:](https://community.home-assistant.io/images/emoji/twitter/sunglasses.png?v=12)