[CDRIVER-1962] Parsing extended JSON datetime Created: 21/Dec/16  Updated: 02/Feb/17  Resolved: 05/Jan/17

Status: Closed
Project: C Driver
Component/s: libbson
Affects Version/s: 1.5.1
Fix Version/s: 1.6.0

Type: Bug Priority: Major - P3
Reporter: Jeroen Ooms [X] Assignee: A. Jesse Jiryu Davis
Resolution: Done Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Epic Link: libbson corpus

 Description   

The datetime.json specification tests contains an example with the following json:

    "extjson": "{\"a\" : {\"$date\" : \"1960-12-24T12:15:30.500Z\"}}",

Converting this to bson with bson_new_from_json gives an error:

Could not parse "1960-12-24T12:15:30.500Z" as a date



 Comments   
Comment by Githook User [ 02/Feb/17 ]

Author:

{u'username': u'jmikola', u'name': u'Jeremy Mikola', u'email': u'jmikola@gmail.com'}

Message: Update BSON corpus XFAILs for issues resolved in libbson 1.6.0

datetime-valid-003.phpt previously failed due to CDRIVER-1962, which was resolved in 1.6.0. It still fails due to CDRIVER-1966, which is slated to be fixed in 1.7.0.
Branch: master
https://github.com/mongodb/mongo-php-driver/commit/cad43d5f664153ecf0ad1c6ff9da9c759f3434a9

Comment by Githook User [ 05/Jan/17 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-1962 delete windows-specific date logic
Branch: master
https://github.com/mongodb/libbson/commit/4f348b3ea498d35b30f541e4d8cb8c68aa46fc20

Comment by Githook User [ 05/Jan/17 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-1962 do all date arithmetic in int64
Branch: master
https://github.com/mongodb/libbson/commit/75a700dbbf4f217feffae63c04a4f182733fa68c

Comment by Githook User [ 05/Jan/17 ]

Author:

{u'username': u'ajdavis', u'name': u'A. Jesse Jiryu Davis', u'email': u'jesse@mongodb.com'}

Message: CDRIVER-1962 allow years from 0000 to 9999
Branch: master
https://github.com/mongodb/libbson/commit/3e8c26fb02eeba46263ed2577088f3234e2b3135

Generated at Wed Feb 07 21:13:44 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.