First, always properly format YAML code following instructions at the top of the page.
Next, for this template sensor you don’t need to use the entity_id config option. It can figure it out from the template. (In fact, since you did use it, but only specified one of the two entities used by the template sensor, it probably won’t update properly.)
Next, if you want the value to be graphed, you need to add the unit_of_measurement config option.
Lastly, it’s probably getting a value of unknown when climate.living_room isn’t ready yet (e.g., at startup.) I.e., the value returned by the state_attr function is probably ‘unknown’. Since you’re using the float function that will pass through the string when it can’t be converted, so ‘unknown’ is passing through. However, if you use the float filter, it will return 0.0 when the input cannot be converted to a float (such as when it is ‘unknown’.)
No problem. For some reason some people have issues using that “preformatted text” button. Not sure why. As I was just telling someone else, the other way is to precede the code with a line that contains just three “back tick” characters, and add a line just like it after the code. So:
```
abc:
xyz: 123
```
That should also properly format the code (instead of using the “preformatted text” button.)
@pnbruckner your advice is working flawless. i immediately changed the rest of my sensor that were bad designed
one note for some reason i need to define the entity_id’s of both sensors involved otherwise the sensor isnt updating, other sensors are working perfect without the entity_id’s as you suggested. but its working now, im a happy man.