Hello,
up until some update all my sensors worked fine, the integration sensors as well as the derived utility sensors.
Somehow now my Integration Sensors now show “Unavailable” as soon as the sensor it is based off has a value of 0…(edit: the value 0 is not the problem, as it has to be 0 from time to time)
Here is what it looks like when I display the entities…
So this is a template question and not a blueprint question, but that said, I noticed that you are using the float filter wrong. That needs to include a default value.
Thanks for the answer. After reading your link more thoroughly I found that as well and corrected it.
My problem is not the power sensors value 0 W. Actually I expect it to be 0W at that moment, since it is supposed to only have a value when the heating is running. Looking at the history that seems to work fine.
My problem is the integration beeing „unavailable“, and following that all utility meters, that are based off it.
This happens only when the power sensor is 0. when the heating is running the other sensors show a value.
Hello Tom,
sorry for wrong categorization. I somehow could not remove it via mobile…
I fixed the float(0) issue as well as added the “device_class” to power.
These are the entities when HEATING is working, Water has not worked that day
For explanation: Power sum sums up all power, and water/heating only get active when the respective service of the heatpump is online.
Why do these sensors go back to “Unavailable” ?
Seems like the integration has problems with the zero-values.
Usually I would want them to show the last state that was valid
Here some screenshots of the data in grafana with "fill(null)
I have the same issue with my shelly utility meters. What exactly did you change to fix the issue?
I noticed that if I turn on the shelly for a second or 2 that the utility meter shows as expected.
I have the same problem you described. It doesn’t help either having, or not having, an ‘availability’ clause (I thought the new format was ‘availability’, not ‘availablity_template’?)
I’m measuring power imported and exported from the grid. If I restart HA or all YAML, either the imported integration OR the exported integration will be ‘unavailable’ depending on whether the house is currently exporting or importing energy. And vice versa. It’s bizarre.
@ItherNiT@spry-salt I assume you could change your value_template or state, so it will be 0, if unavailable:
Below is an example. Only if value is greater than 0, use the value, otherwise it will be 0.
Other ideas:
Also you might want to experiment with the float or float(0). That might get it to work.
Also note it is common that the daily and integration sensors need some data in order to work become available. The daily sensor should become available latest at 0:00 since it resets, so you could try to wait.
Integration sensor usually also takes some time to become available.
I also face the same issue using 2023.8.1.
The integration sensor becomes unavailable once the source sensor is 0.
Does anyone know whether this is being fixed?