-
Notifications
You must be signed in to change notification settings - Fork 196
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
Fix RFC3339 representation #150
Conversation
Thanks for the contribution and sorry for the long wait. The change looks good. Would you be up for writing a test to ensure that the RFC3339 is correctly implemented? 🎉 |
Sure, I try not to forget it. |
Great! Ready when you are 🎉 |
I get 10 failed tests on macOS before I even start (also on |
Yes, they should. Can you open a new issue with some more information about the test failures you get? |
Must be at most 1-digit millisecond.
Thanks for the contribution 🎉 |
I've released v0.4.3 containing this fix! |
To fix the originally reported problem someone would have to deploy that latest version for https://now.httpbin.org/ |
That "someone" would be Kenneth. I see what I can do. |
@kennethreitz - ping, how about upgrading httpbin.org? |
https://now.httpbin.org/ returns an invalid RFC3339 representation. It currently shows 2-digit milliseconds. I hope I tracked it correctly back to Maya
core.py
.RFC3339 5.6 allows at most 1 digit for milliseconds: https://tools.ietf.org/html/rfc3339#section-5.6.
I'm not 100% happy with the fix as
.%f
apparently isn't guaranteed to always return 6 digits (platform dependent). https://stackoverflow.com/a/35643540/131929 shows a more stable version based on splitting and reformatting the original string.