Join GitHub today
GitHub is home to over 20 million developers working together to host and review code, manage projects, and build software together.
Pyephem doesn't catch moonset in next 13+ hours at 89.5 latitude #32
The code above yields the "ephem.AlwaysUpError: 'Moon' is still above the horizon at 2013/11/26 18:37:06" error.
However, if change the date to "2013/11/26 18:38", you get:
which is the correct answer.
Shouldn't next_setting() catch settings that occur within 24 hours?
For reference, libnova does the same thing, see http://stackoverflow.com/questions/19862226/libnova-odd-behavior-for-89-5-degrees-north-latitude for details.
I have finally had some time to look at your issue, and in the process remind myself how the whole rising-and-setting engine works. Here is an IPython Notebook where I did some graphing and tracing until I figured out what was going on:
The answer to your question is that, no,
I will update the Quick Reference and the docstrings for those functions to try to make this distinction clear — I'm sorry that they confused you and wasted some of your time wondering why!
There! Hopefully that will help things. I am planning for a release on Friday, which will make these changes available if you upgrade. Thanks for letting me know that this was frustrating, and feel free to re-open this issue if you have a further suggestion that could make this PyEphem feature even less confusing.