Closed Simovaara closed 1 year ago
This happened again yesterday, SHF Cheapest period start helper was not updated until 00:00. This might be to late if cheapest period starts at the same time. I wonder why this update is not happening soon after new Nordpool prices are out.
There have been some problems with this "SHF Cheapest period" sensor. At least one known bug currently is that the calculation takes into account all prices starting from "today 0:00:00". In some cases it could be that the cheapest n hours determined by this system are actually in the past and therefore the sensor does not get updated accordingly. The sensor recalculates values when "tomorrow" changes to "today" and this might be why you are seeing this behaviour.
One extra problem with this is that the next cheapest n hours could be during the afternoon, next night or during tomorrow evening. And you cannot predict that. Therefore, I am working on a solution that would calculate cheapest n hours between today 15:00 and tomorrow 15:00 as usually most of the cheapest hours are during the night but cheapest period could start at 23:00 in some cases (this scheme would take advantage of cheapest n hours spanning on two separate days). And it would also ensure that there is at least 1 "cheapest n hour period" during 24 hours. Time span starting from 15 o'clock was selected as the prices are usually released roughly at 14 and the new values should be available soon after that.
Does this sound reasonable? I am going to push updated code soon as it has been running on my instance
I have now pushed an update to the main repository. It contains updated code which tries to ensure that there is one "cheapest period" between today 15 o'clock and tomorrow 15 o'clock.
Feel free to test this and report back if it works.
Thanks, I will try this out and report asap.
This seems to working fine with version 0.1.9, so I will close the issue. Thank you for the quick fix!
Hello and thank you for the great work!
I have been using "SHF Cheapest period start" to trigger my house heatings to turn on when cheap hours are starting. So far this has been working fine, but today cheap hours were starting at 00:00 and "SHF Cheapest perior start helper" was updated at excatly the same time. This caused my automations not to trigger. Is there a way to force update of "SHF Cheapest period start" earlier to prevent this or something else that should be changed?