Recently, on some days, I am seeing huge energy spikes at midnight. I assume that the previous days values are being taken into consideration before the sensors reset, or something like that.
I didn’t find a fix. It seems to occur much less often now. But it happens quite a lot if I restart home assistant frequently (when I’m developing integrations and need to keep restarting to use new code)