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

ephem ignores the microseconds in `datetime.datetime` objects. #29

Closed
kiyo-masui opened this Issue Oct 30, 2013 · 3 comments

Comments

Projects
None yet
2 participants
@kiyo-masui

kiyo-masui commented Oct 30, 2013

ephem seems to be ignoring the microseconds in the builtin datetime objects. I've pasted three examples below. The first two should not give identical output. In the third, I convert to a string first and this seems to work fine.

>>> import ephem
>>> import datetime
>>> ephem.date(datetime.datetime(2000, 12, 25, 12, 41, 16, 10))
36884.028657407405
>>> ephem.date(datetime.datetime(2000, 12, 25, 12, 41, 16, 10000))
36884.028657407405
>>> ephem.date(str(datetime.datetime(2000, 12, 25, 12, 41, 16, 10000)))
36884.02865752315
>>> ephem.__version__
'3.7.5.1'

brandon-rhodes added a commit that referenced this issue Oct 31, 2013

@brandon-rhodes

This comment has been minimized.

Owner

brandon-rhodes commented Oct 31, 2013

I think I have fixed it — could you run the following install command to try out this new version and let me know if it works?

pip install https://github.com/brandon-rhodes/pyephem/archive/master.zip

Thanks!

@kiyo-masui

This comment has been minimized.

kiyo-masui commented Oct 31, 2013

Yup that did the trick!

How long will it take to propagate this to pypi? Will you be incrementing the minor version number for this fix (so my module can check for the fix at runtime)?

@ghost ghost assigned brandon-rhodes Dec 12, 2013

brandon-rhodes added a commit that referenced this issue Dec 12, 2013

@brandon-rhodes

This comment has been minimized.

Owner

brandon-rhodes commented Dec 21, 2013

The fix has now been released as 3.7.5.2. Enjoy!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment