Groups
Groups
Sign in
Groups
Groups
golang-nuts
Conversations
About
Send feedback
Help
More details regarding changes to time.Time JSON marshalling/unmarshalling in 1.20?
134 views
Skip to first unread message
Ben Brcan
unread,
Jan 4, 2023, 2:54:50 AM
1/4/23
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to golang-nuts
Hi, I noticed this in the draft release notes for 1.20:
The
Time.MarshalJSON
and
Time.UnmarshalJSON
methods are now more strict about adherence to RFC 3339.
Can we get some further details about this? Are there things that were OK before that will no longer be valid?
Thank you
Ben
Dan Kortschak
unread,
Jan 4, 2023, 3:10:49 AM
1/4/23
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to golan...@googlegroups.com
I'd say it's this:
https://github.com/golang/go/commit/72c58fb77192f7d17d87663c943360a48aae11dc
gbarr
unread,
Jan 4, 2023, 3:13:52 AM
1/4/23
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to golang-nuts
By reading the commit at
https://github.com/golang/go/commit/72c58fb77192f7d17d87663c943360a48aae11dc
the change that stands out most to me is bounds checking on the hour and minute elements of the time zone offset
Ben Brcan
unread,
Jan 4, 2023, 5:03:46 PM
1/4/23
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to golang-nuts
That's really helpful, thank you!
Reply all
Reply to author
Forward
0 new messages