You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
As noted in http://stackoverflow.com/q/23828573, the JSON serialisation format
for OffsetDateTime produces output such as "2014-05-16T07:28:51+02" (it uses
OffsetDateTimePattern.ExtendedIsoPattern).
However, ECMA-262 requires that the offset be specified including the minutes
(see http://www.ecma-international.org/ecma-262/5.1/#sec-15.9.1.15), and at
least Chrome fails to parse the string otherwise:
> Date.parse("2014-05-16T07:28:51+02")
NaN
> Date.parse("2014-05-16T07:28:51+02:00")
1400218131000
(The spec _also_ requires the milliseconds field, if present, to be three
decimals, rather than the six we generate. However, that appears not to cause
trouble in practice, so we might not want to change that.)
While JSON doesn't necessarily mean that you're parsing with JavaScript, it
seems reasonable to at least consider changing the serialization format to
always include the minutes.
Original issue reported on code.google.com by malcolm.rowe on 24 May 2014 at 9:04
The text was updated successfully, but these errors were encountered:
Original issue reported on code.google.com by
malcolm.rowe
on 24 May 2014 at 9:04The text was updated successfully, but these errors were encountered: