-
-
Notifications
You must be signed in to change notification settings - Fork 56
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
Support for RFC 3339 in target time zone #376
Comments
Sorry, looks like parsing already works as expected via the |
Thank you for reporting this. I believe I have a fix in #378, but it needs some testing. |
Also, there's no need to do |
Yeah, I tried that first but noted that it displayed in UTC. Didn’t realize that was unexpected behavior. |
For |
I think it’s best to return the specified TZ offset for consistency. Users can always convert to local after parsing, but it’s otherwise difficult to recover the original offset. |
I'm not able to get times to print in RFC 3339 using the
format_datetime
function:According to the chrono docs,
%z
and friends should give the local offset relative to UTC. However, it looks like the TZ info is getting dropped before being sent to the formatter and it's always displaying in UTC. (I would also like to add formatters/parsers for the reference format to the prelude, but I'm not sure if others would find that useful.)The text was updated successfully, but these errors were encountered: