Uploaded image for project: 'Go Driver'
  1. Go Driver
  2. GODRIVER-1514

Extended JSON $date incorrectly parses single-digit hours

    • Type: Icon: Bug Bug
    • Resolution: Won't Do
    • Priority: Icon: Major - P3 Major - P3
    • None
    • Affects Version/s: 1.3.0
    • Component/s: JSON & ExtJSON
    • None

       The driver incorrectly parses a single-digit hour for $date:

      {"":{"$date":"0070-01-01T0:00:00Z"}}
      

      It should error because ISO 8601 (and RFC-3339) require a two-digit hour.

      This turns out to be a Go bug (#37616), but can be fixed by changing the parsing format string to 2006-01-02T03:04:05Z07:00 custom validation.

            Assignee:
            Unassigned Unassigned
            Reporter:
            david.golden@mongodb.com David Golden
            Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

              Created:
              Updated:
              Resolved: