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

Converting states of history_stat sensors

$
0
0

I am using this sensor to check the amount of time my SkyQ decoder worked last 24 hours:

- platform: history_stats
  name: SkyQ ON Ieri
  entity_id: media_player.sky_q
  state: "playing"
  type: time
  end: "{{ now().replace(hour=0, minute=0, second=0) }}"
  duration:
    hours: 24

And before upgrading to the latest release of HA (2022.5.2) the sensor had also an attribute showing the real hours and minutes while the state were showing an absolute number like 9.89.
Now, with the latest release the attribute disappeared and the state actually shows 9.89 hours.
How to convert this state to real hours and minutes? Or how to have back the attribute?
P.S. Hope you understand what i mean due to my poor english…

1 post - 1 participant

Read full topic


Viewing all articles
Browse latest Browse all 103323

Trending Articles



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