Open AndreKR opened 2 days ago
Hey there @swamp-ig, mind taking a look at this issue as it has been labeled with an integration (sun
) you are listed as a code owner for? Thanks!
(message by CodeOwnersMention)
sun documentation sun source (message by IssueLinks)
The first screenshot is a logbook entry which just means that at 16:30 the sensor "Sun Next setting" has been set to "November 28, 2024". The new state is just a date because of limited accuracy of visible log book entries. So it doesn't mean, that the next sun set is at 16:30, but the the state has been changed at 16:30. You can check the state in the Developer tools -> states tab
The first screenshot is a logbook entry which just means that at 16:30 the sensor "Sun Next setting" has been set to "November 28, 2024".
I'm reasonably sure that the "at 16:30" is part of the value and not the time that it was changed.
Here are more logbook entries as well as the current state:
As you can see the "at xx:xx" part corresponds to the time in the value and not to the time the logbook entry was made.
The problem
To my understanding the sensor
sun_next_setting
should contain the time of the next time that thesun.sun
entity will change fromabove_horizon
tobelow_horizon
.I found there is a difference between those two times.
You can see that the sun was supposed to set at 16:30, but in fact it set at 16:34.
What version of Home Assistant Core has the issue?
core-2024.9.3
What was the last working version of Home Assistant Core?
No response
What type of installation are you running?
Home Assistant Container
Integration causing the issue
Sun
Link to integration documentation on our website
https://www.home-assistant.io/integrations/sun/
Diagnostics information
No response
Example YAML snippet
No response
Anything in the logs that might be useful for us?
No response
Additional information
It might be interesting why this is an issue. I'm using this template sensor to control when my blinds should be down (from 15 minutes before sunset to sunrise):
Because of the bug my blinds go down at 16:16, then up again at 16:30 (when the time of
sun_next_setting
is reached) and then down again at 16:34 (whensun.sun
actually changes tobelow_horizon
).