Commit Graph

79 Commits

Author SHA1 Message Date
Shane Harvey
a7579b02d2
PYTHON-3259 Improve migration guide for loads/JSONOptions/tz_aware (#946) 2022-05-10 11:05:59 -07:00
Steven Silvester
a0fe7c03af
PYTHON-3120 Set up flake8 linting (#868) 2022-02-17 06:44:08 -06:00
Steven Silvester
5578999a90
PYTHON-1834 Use a code formatter (#852) 2022-02-09 06:44:28 -06:00
Steven Silvester
52ed5a4135
PYTHON-3052 Add Typings to PyMongo Itself (#829) 2022-01-13 16:09:48 -06:00
Julius Park
70f7fe7542
PYTHON-3028 $regex as a field name does not allow for non-string values (#807) 2021-12-06 13:13:15 -08:00
Julius Park
23fe13fcba
PYTHON-1965 The bson package should not depend on the pymongo package (#725) 2021-09-15 12:56:18 -07:00
Julius Park
e3771587c3
PYTHON-1949 CodecOptions and JSONOptions should have the same default value for tz_aware (#720) 2021-09-14 16:54:11 -07:00
Shane Harvey
fb20975a1f
PYTHON-2245 Change default uuidRepresentation to UNSPECIFIED (ie disable UUID encoding by default) (#724)
This change also stops decoding both 3 and 4 subtypes as UUIDs.
With standard, only subtype 4 is decoded to UUID and subtype 3 is decoded to Binary.
With legacy representations, only subtype 3 is decoded to UUID and subtype 4 is decoded to Binary.
2021-09-14 16:48:52 -07:00
Shane Harvey
afa3997bb2
PYTHON-2680 Breaking changes to DBRef BSON+JSON decoding (#722)
Implement DBRef spec version 1.0 tests.
2021-09-10 11:03:25 -07:00
Julius Park
7a4b617b5d
PYTHON-2883 Regex decoding error tests in top.json have unexpected, invalid syntax (#721) 2021-09-09 18:32:53 -07:00
Shane Harvey
fb38fbe35e
PYTHON-2046 Change default JSONMode and dumps output from LEGACY to RELAXED (#711) 2021-09-08 11:33:41 -07:00
Shane Harvey
69c69a6bfb
PYTHON-2862 Remove versionchanged info for PyMongo <3.0 (#709) 2021-08-19 10:39:26 -07:00
Bernie Hackett
521f7b9af4 PYTHON-2133 Fix up docs
And finish deleting python 2 specific code.
2021-01-21 15:49:23 -08:00
Bernie Hackett
c70071df1d PYTHON-2133 Remove Py2 compatibility from bson 2021-01-14 14:57:20 -08:00
Prashant Mital
4119d35d04
PYTHON-2440 Workaround namedtuple._asdict() bug on Python 3.4 (#525) 2020-11-24 12:11:22 -08:00
Prashant Mital
dc94ca628e
PYTHON-2361 Support parsing as extended JSON representation for subtype 4 binary (#483) 2020-09-09 17:24:29 -07:00
Prashant Mital
963759af33
PYTHON-2354 Add support for JSONOptions.with_options (#482) 2020-09-09 14:15:21 -07:00
Prashant Mital
f24e165336
PYTHON-2263 Respect UuidRepresentation.UNSPECIFIED when parsing $uuid fields in extended JSON (#464) 2020-07-13 11:03:02 -07:00
Prashant Mital
4760d07815
PYTHON-2152 Expand native UUID handling support; Implement UUID specification 2020-06-01 17:45:08 -07:00
Anders Kaseorg
bb18da769c PYTHON-2001 Fix Python 3.8 SyntaxWarning: "is not" with a literal (#425)
Fixes this warning from Python 3.8:
bson/json_util.py:702: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if doc['$minKey'] is not 1:
bson/json_util.py:711: SyntaxWarning: "is not" with a literal. Did you mean "!="?
  if doc['$maxKey'] is not 1:
2019-10-24 14:08:08 -05:00
Shane Harvey
8855a510a8 PYTHON-1875 Fix parsing of json datetime without timezone or fractional seconds
{"$date": "2019-01-01T01:02:03"} is now parsed the same as
{"$date": "2019-01-01T01:02:03Z"},
{"$date": "2019-01-01T01:02:03.000"}, and
{"$date": "2019-01-01T01:02:03.000Z"}
2019-06-24 16:20:34 -07:00
Bernie Hackett
749c1a2f0b PYTHON-1467 - PyMongo no longer supports Python 2.6 2018-07-02 15:15:43 -07:00
Bernie Hackett
507f954ed4 Update copyright dates 2017-12-01 17:23:39 -08:00
Bernie Hackett
410027c057 PYTHON-1387 - Improve detection of object_pairs_hook support 2017-09-30 09:28:09 -07:00
Shane Harvey
b7893b7ec4 3.5 changelog and documentation fixes. 2017-08-08 09:32:09 -07:00
Shane Harvey
6e022e0636 PYTHON-1297 Improve documentation for Extended JSON. 2017-08-07 17:14:34 -07:00
Shane Harvey
054a01aaff PYTHON-1297 Implement Extended JSON Spec 2.0
Add JSONOptions.json_mode to control encoding Relaxed and Canonical
Extended JSON.
Add json_util.LEGACY_JSON_OPTIONS to encode PyMongo 3.4's default JSON output.
Deprecate json_util.STRICT_JSON_OPTIONS.
Move Decimal128 spec tests to bson_corpus runner.
2017-08-03 10:30:24 -07:00
Shane Harvey
6a11888a9c PYTHON-1330 Decode JSON binary type 0 to Python 3 bytes. 2017-07-31 13:16:46 -07:00
Luke Lovett
74c0d55314 PYTHON-1214 - Implement the extended JSON specification. 2017-02-22 10:32:29 -08:00
Bernie Hackett
afa14fb3a2 Link to python-bsonjs on pypi 2016-11-29 09:31:27 -08:00
Shane Harvey
0abcb7a683 Advertise python-bsonjs in json_util and FAQ documentation 2016-11-28 17:36:40 -08:00
Bernie Hackett
c0767a551a PYTHON-1153 - Make docs build and test under python 3 2016-09-26 15:49:59 -07:00
Shane Harvey
888d0fab1f PYTHON-1135 Replace JSONOptions.strict_date with JSONOptions.datetime_representation 2016-09-12 11:11:30 -07:00
Bernie Hackett
82db71e1e8 PYTHON-1068 - Support for BSON Decimal128 2016-08-29 15:07:07 -07:00
Luke Lovett
b6c74cf33d PYTHON-1106 - Implement BSON corpus test suite. 2016-08-24 11:01:45 -07:00
Luke Lovett
6692e8877a PYTHON-1131 - Fix inconsistent handling of scope, unicode support for Code. 2016-08-19 15:22:19 -07:00
Shane Harvey
6e2ecc1817 PYTHON-1111 JSONOptions.document_class requires simplejson in Python2.6 2016-08-01 10:05:16 -07:00
Shane Harvey
57d1ccde2f PYTHON-1111 Add JSONOptions for dumps and loads
PYTHON-767 Support JSON strict mode $date output
PYTHON-1039 Support JSON strict mode $numberLong output
PYTHON-1103 Support JSON strict mode UUID output
PYTHON-1111 Support custom document class in loads
PYTHON-1111 Support tz_aware and tzinfo in loads
Refactor milliseconds to datetime conversions
2016-07-27 11:32:59 -07:00
Shane Harvey
5afd19922a PYTHON-1111 Add JSONOptions for dumps and loads 2016-07-22 12:10:29 -07:00
Bernie Hackett
59d8fdadc1 PYTHON-1058 - Support decoding datetime.isoformat format for $date
This change also adds support for the (+|-)HH offset format.
2016-05-20 13:12:47 -07:00
Bernie Hackett
aec685b374 Fix up copyright dates. 2015-03-25 11:55:02 -07:00
Bernie Hackett
bba49fd618 PYTHON-864 - Support RFC-3339 offset format for $date. 2015-03-20 16:23:55 -07:00
A. Jesse Jiryu Davis
2ba730722b PYTHON-526 Remove 'compile_re' option.
PyMongo now never attempts to compile BSON regular expressions as Python native
regular expressions.
2014-12-05 14:06:38 -05:00
A. Jesse Jiryu Davis
2c6483b348 Rely on standard json module.
Now that we've dropped Python 2.4 and 2.5, we know the standard json module is
available.
2014-12-03 16:32:41 -05:00
Bernie Hackett
5aee3e1b31 PYTHON-791 - Fix JSON support for Timestamp. 2014-11-21 14:35:48 -08:00
A. Jesse Jiryu Davis
08dccbba46 Remove ancient version annotations.
Delete "versionchanged" and "versionadded" directives that predate 2.0.
2014-10-31 14:15:24 -04:00
Bernie Hackett
9c8852d93f PYTHON-760 - BSONInt64 -> Int64 2014-09-23 11:43:41 -07:00
Bernie Hackett
6595657128 PYTHON-759 - Support $date as ISO-8601 or $numberLong 2014-09-17 14:02:18 -07:00
Luke Lovett
35c7445a67 PYTHON-708 Support $undefined and $numberLong extended JSON types. 2014-07-18 16:46:35 +00:00
Bernie Hackett
2b79325d3b PYTHON-686 - Remove a bunch of references to 2.4 and 2.5 2014-04-24 12:40:29 -07:00