Skip to content

Commit

Permalink
PYTHON-2797 Update changelog for 5.0 support (#675)
Browse files Browse the repository at this point in the history
  • Loading branch information
ShaneHarvey committed Jul 13, 2021
1 parent 7f5df56 commit 6cdc6a2
Show file tree
Hide file tree
Showing 5 changed files with 39 additions and 8 deletions.
2 changes: 1 addition & 1 deletion README.rst
Expand Up @@ -17,7 +17,7 @@ is a `gridfs
<http://www.mongodb.org/display/DOCS/GridFS+Specification>`_
implementation on top of ``pymongo``.

PyMongo supports MongoDB 2.6, 3.0, 3.2, 3.4, 3.6, 4.0, 4.2, and 4.4.
PyMongo supports MongoDB 2.6, 3.0, 3.2, 3.4, 3.6, 4.0, 4.2, 4.4, and 5.0.

Support / Feedback
==================
Expand Down
2 changes: 1 addition & 1 deletion doc/api/pymongo/collection.rst
Expand Up @@ -48,7 +48,7 @@
.. automethod:: aggregate_raw_batches
.. automethod:: watch
.. automethod:: find(filter=None, projection=None, skip=0, limit=0, no_cursor_timeout=False, cursor_type=CursorType.NON_TAILABLE, sort=None, allow_partial_results=False, oplog_replay=False, modifiers=None, batch_size=0, manipulate=True, collation=None, hint=None, max_scan=None, max_time_ms=None, max=None, min=None, return_key=False, show_record_id=False, snapshot=False, comment=None, session=None, allow_disk_use=None)
.. automethod:: find_raw_batches(filter=None, projection=None, skip=0, limit=0, no_cursor_timeout=False, cursor_type=CursorType.NON_TAILABLE, sort=None, allow_partial_results=False, oplog_replay=False, modifiers=None, batch_size=0, manipulate=True, collation=None, hint=None, max_scan=None, max_time_ms=None, max=None, min=None, return_key=False, show_record_id=False, snapshot=False, comment=None, allow_disk_use=None)
.. automethod:: find_raw_batches(filter=None, projection=None, skip=0, limit=0, no_cursor_timeout=False, cursor_type=CursorType.NON_TAILABLE, sort=None, allow_partial_results=False, oplog_replay=False, modifiers=None, batch_size=0, manipulate=True, collation=None, hint=None, max_scan=None, max_time_ms=None, max=None, min=None, return_key=False, show_record_id=False, snapshot=False, comment=None, session=None, allow_disk_use=None)
.. automethod:: find_one(filter=None, *args, **kwargs)
.. automethod:: find_one_and_delete
.. automethod:: find_one_and_replace(filter, replacement, projection=None, sort=None, return_document=ReturnDocument.BEFORE, hint=None, session=None, **kwargs)
Expand Down
31 changes: 30 additions & 1 deletion doc/changelog.rst
Expand Up @@ -16,20 +16,46 @@ Changes in Version 3.12.0
Notable improvements
....................

- Added support for MongoDB 5.0.
- Support for MongoDB Versioned API, see :class:`~pymongo.server_api.ServerApi`.
- Support for snapshot reads on secondaries (see :ref:`snapshot-reads-ref`).
- Support for Azure and GCP KMS providers for client side field level
encryption. See the docstring for :class:`~pymongo.mongo_client.MongoClient`,
:class:`~pymongo.encryption_options.AutoEncryptionOpts`,
and :mod:`~pymongo.encryption`.
- Support AWS authentication with temporary credentials when connecting to KMS
in client side field level encryption.
- Support for connecting to load balanced MongoDB clusters via the new
``loadBalanced`` URI option.
- Support for creating timeseries collections via the ``timeseries`` and
``expireAfterSeconds`` arguments to
:meth:`~pymongo.database.Database.create_collection`.
- Added :attr:`pymongo.mongo_client.MongoClient.topology_description`.
- Added hash support to :class:`~pymongo.mongo_client.MongoClient`,
:class:`~pymongo.database.Database` and
:class:`~pymongo.collection.Collection` (`PYTHON-2466`_).
- Improved the error message returned by
:meth:`~pymongo.collection.Collection.insert_many` when supplied with an
argument of incorrect type (`PYTHON-1690`_).
- Added session and read concern support to
:meth:`~pymongo.collection.Collection.find_raw_batches`
and :meth:`~pymongo.collection.Collection.aggregate_raw_batches`.

Bug fixes
.........

- Fixed a bug that could cause the driver to deadlock during automatic
client side field level encryption (`PYTHON-2472`_).
- Fixed a potential deadlock when garbage collecting an unclosed exhaust
:class:`~pymongo.cursor.Cursor`.
- Fixed an bug where using gevent.Timeout to timeout an operation could
lead to a deadlock.
- Fixed the following bug with Atlas Data Lake. When closing cursors,
pymongo now sends killCursors with the namespace returned the cursor's
initial command response.
- Fixed a bug in :class:`~pymongo.cursor.RawBatchCursor` that caused it to
return an empty bytestring when the cursor contained no results. It now
raises :exc:`StopIteration` instead.

Deprecations
............
Expand All @@ -46,7 +72,10 @@ Deprecations
- Deprecated :class:`~pymongo.ismaster.IsMaster` and :mod:`~pymongo.ismaster`
which will be removed in PyMongo 4.0 and are replaced by
:class:`~pymongo.hello.Hello` and :mod:`~pymongo.hello` which provide the
same API.
same API.
- Deprecated the :mod:`pymongo.messeage` module.
- Deprecated the ``ssl_keyfile`` and ``ssl_certfile`` URI options in favor
of ``tlsCertificateKeyFile`` (see :doc:`examples/tls`).

.. _PYTHON-2466: https://jira.mongodb.org/browse/PYTHON-2466
.. _PYTHON-1690: https://jira.mongodb.org/browse/PYTHON-1690
Expand Down
2 changes: 2 additions & 0 deletions pymongo/client_session.py
Expand Up @@ -93,6 +93,8 @@
.. mongodoc:: transactions
.. _snapshot-reads-ref:
Snapshot Reads
==============
Expand Down
10 changes: 5 additions & 5 deletions pymongo/database.py
Expand Up @@ -360,14 +360,14 @@ def create_collection(self, name, codec_options=None,
Options should be passed as keyword arguments to this method. Supported
options vary with MongoDB release. Some examples include:
- "size": desired initial size for the collection (in
- ``size``: desired initial size for the collection (in
bytes). For capped collections this size is the max
size of the collection.
- "capped": if True, this is a capped collection
- "max": maximum number of objects if capped (optional)
- `timeseries`: a document specifying configuration options for
- ``capped``: if True, this is a capped collection
- ``max``: maximum number of objects if capped (optional)
- ``timeseries``: a document specifying configuration options for
timeseries collections
- `expireAfterSeconds`: the number of seconds after which a
- ``expireAfterSeconds``: the number of seconds after which a
document in a timeseries collection expires
See the MongoDB documentation for a full list of supported options by
Expand Down

0 comments on commit 6cdc6a2

Please sign in to comment.