mampfes / ha_epex_spot_sensor

Provides helper sensors for EPEX Spot integration.
MIT License
48 stars 4 forks source link

Spot sensor Status Unknown #3

Closed pabe40 closed 6 months ago

pabe40 commented 6 months ago

I find your addition to EPEX Spot usefull and looking forward to use it. Issues with Latest End Time setting smaller than earliest start time.

Latest time to end the appliance. Set it to same value as earliest start time to cover 24h. If set to smaller value than earliest start time, it automatically refers to following day.

When doing so, the status becomes unknown.

ps: setting the same time for both only works when both set to 12:00:00 AM.

mampfes commented 6 months ago

Ok, I see the problem:

When switching from one day to the other, the old data will be discarded. Therefore, the integration can't calculate the start time anymore and sets the sensor state to invalid. I need to cache the historic data.

mampfes commented 6 months ago

5

ready for testing

mampfes commented 6 months ago

fixed in latest commit