Energy dashboard becoming more and more unreliable

Lately, the energy dashboard is becoming more an more unreliable because of glitches in the solartotal entity, while there is nothing special to see in the solar power production graph, and those glitches occur at night, when there is no solar production at all.
Can anyone help me to solve this ?

It started about 2 months ago, but it is becoming more and more frequent.
image
As you can see, this results in totally crazy readings of solar production, energy injection, an power consumption.
image

Here you can see the glitches happening when at a time the solar inverter has not started yet
image
Here they are in more detail
image
And here is the graph that represents the output power of the solar inverter
There are no glitches there, it looks perfectly normal.
image

This is not an issue with the energy dashboard it is an issue with your solar energy sensor.

Which integration are you using to gather your solarenergytoday sensor data?

Please supply all the configuration details as well as a link to the integration used.

1 Like

Thanks for your reply, your question to give more details made me look at things a bit in more detail, and I found a strange thing in a helper function.

I did not suspect the solar energy integration, as the power production output is completely correct.

This is the integration I use

This is how it is configured

And this is its output
image

Then I created a helper function to multiply the output by 2.5, because I have a second solar inverter that I cannot integrate into HA, but it has the same orientation.
So I use the output of this helper function in the energy dashboard, to represent the common output of my 2 solar systems

And in the output of the helper function I see a glitch
image

Any ideas why a simple multiplication would cause this glitch ?

When your sunnybeam energy sensor becomes unavailable the float filter replaces the value with the default of zero. That’s what the (0) is in this → |float(0)

Try just |float instead and hope the helper has an implied availability template. If it does not then errors will be generated and recorded in Settings → System → Logs.

You can overcome this by using yaml where you can supply an availability template. See: Why an availability template is important for energy template sensors

Thanks,

I changed the float filter, and will read up on your contribution about using an availability template .

Can you help me add this availability line in my helper template sensor please ?
When I try to add it, I get several syntax errors.

image

Not like that, no. As I said:

You need to define the sensor in YAML not in a UI helper.

# configuration.yaml

template:
  - sensor:
      - name: etc...

OK, thx, I’ll create a AML template.

The developper of the integration told me to use a helper to do the multiplication, instead of changing directly in the integration Python code, to avoid having to change the integration code each time there is an update.

It is a bit confusing to know when to do something in UI and when to do it in YAML, as HA seems to be changing more and more things to the UI now, and more and more integrations ask to delete the YAML config in favor of UI config.