-
Notifications
You must be signed in to change notification settings - Fork 46
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Astral fails to correctly calculate sunrise and sunset times in unique test case of Norwegian Winter #67
Comments
Same here.
|
It seems the solution can be achieved by edit this line of code Lines 363 to 370 in 96496f0
|
@yasirroni thanks, but what is that ? - it's not committed, not a PR? - will it make into a release soon? |
That is the code that astral use that we need to edit and make a PR to solve local timezone bug changing day. |
See suntime package. Basically they reproduce the same bug and I already fix that on suntime. Haven't got time to fix here too. I just pin point the problem for those willing to solve it. |
@yasirroni unfortunatly, I can not use suntime due to SatAgro/suntime#18 |
Have you try my fork on test-pypi? Go to test-pypi and search suntime-yasirroni |
@yasirroni thanks, but I try to stick to libraries from pip or so, to prevent wild searching and retracing what I did when something needs to run on another distro/hardware x years later. |
Then, you can fork it and publish it on pypi yourself. Easy, hahaa |
Thanks I had that problem today, astral was showing error, "Unable to find a dawn time on the date specified". After applying your correction it works fine. Thank you very much. I did one correction though : "eq_of_time(t)" I replaced t with jc for jc = julianday_to_juliancentury(jd + adjustment) |
Produces:
2010-01-01 00:00:00+00:00
2009-12-31 23:53:51.078028+00:00 <==Sunrise Time
2010-01-01 02:33:44.399907+00:00 <==Sunset Time
2009-12-31 23:54:06.078028+00:00 <== Adjust time to Sunrise Time + 15 seconds
2009-12-30 23:55:49.136837+00:00 <== New Sunrise Time
2009-12-31 02:30:47.610544+00:00 <== New Sunset Time
The text was updated successfully, but these errors were encountered: