-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Changelog 4.3 #1038
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changelog 4.3 #1038
Conversation
doc/changelog.rst
Outdated
PyMongo 4.3 brings a number of improvements including: | ||
|
||
- Improved support for documents with BSON datetimes outside of the range | ||
supported by Python. See :ref:`handling-out-of-range-datetimes` for examples. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's link to all of the new APIs too: MongoCLient's datetime_conversion arg, the DatetimeMS class, the enum, etc..
doc/changelog.rst
Outdated
- Improved support for documents with BSON datetimes outside of the range | ||
supported by Python. See :ref:`handling-out-of-range-datetimes` for examples. | ||
- Improved support for avoiding deadlocking when a ``fork()`` occurs with an | ||
:class:`~pymongo.mongo_client.MongoClient`. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say "Add support for using a MongoClient before+after a fork()"
doc/changelog.rst
Outdated
- Improved support for avoiding deadlocking when a ``fork()`` occurs with an | ||
:class:`~pymongo.mongo_client.MongoClient`. | ||
- Refactored several underlying classes in :mod:`pymongo.monitoring` for | ||
connection events. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We don't need to mention the refactor since it doesn't affect end users.
doc/changelog.rst
Outdated
|
||
- Updated :class:`~pymongo.change_stream.ChangeStream` so that it will | ||
close after non-resumable non-timeout errors, and will resume its connection | ||
otherwise. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'd say "Fixed a bug where ChangeStream would allow an app to retry calling next() or try_next() even after non-resumable errors (PYTHON-3389
_)"
doc/changelog.rst
Outdated
|
||
.. _PYTHON-1824: https://jira.mongodb.org/browse/PYTHON-1824 | ||
.. _PYTHON-2484: https://jira.mongodb.org/browse/PYTHON-2484 | ||
.. _PYTHON-3312: https://jira.mongodb.org/browse/PYTHON-3312 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Let's reference these inline like:
- Improved support for documents with BSON datetimes outside of the range
supported by Python. See :ref:`handling-out-of-range-datetimes` for examples (`PYTHON-1824`_).
doc/changelog.rst
Outdated
|
||
PyMongo 4.3 brings a number of improvements including: | ||
|
||
- Improved support for documents with BSON datetimes outside of the range |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
"Improved support for documents with" -> "Added support for decoding BSON datetimes outside of the range supported by Python's datetime.datetime."
doc/faq.rst
Outdated
using a client will result in all locks held by :class:`~bson.objectid | ||
.ObjectId` and :class:`~pymongo.mongo_client.MongoClient` being released. | ||
In addition, instances of :class:`~pymongo.topology.Topology` will be | ||
replaced with identical settings. This feature is only available on |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I would avoid mentioning details like the specific locks or Topology objects that we sanitize. Instead let's just say that PyMongo sanitizes its locks and shared state in the child process after fork() and hence pymongo is fork() safe (with caveats about compatible systems).
doc/faq.rst
Outdated
deadlock in the child process due to the inherent incompatibilities between | ||
``fork()``, threads, and locks described :ref:`below | ||
<pymongo-fork-safe-details>`. PyMongo will attempt to issue a warning if | ||
there is a chance of this deadlock occurring. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we just remove all the outdated sections now that pymongo is fork safe? The old non-fork safe behavior will still be readable on the docs for old versions on pymongo.
doc/changelog.rst
Outdated
:ref:`handling-out-of-range-datetimes` for examples, as well as | ||
:class:`pymongo.datetime_ms.DatetimeMS`, | ||
:attr:`pymongo.codec_options.CodecOptions.datetime_conversion`, | ||
:class:`pymongo.datetime_ms.DatetimeConversion` for more details |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These 3 links don't render correctly: https://pymongo--1038.org.readthedocs.build/en/1038/changelog.html?highlight=datetime_#changes-in-version-4-3
doc/changelog.rst
Outdated
PyMongo 4.3 brings a number of improvements including: | ||
|
||
- Added support for decoding BSON datetimes outside of the range supported | ||
by Python's :class:`~datetime.datetime` See |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Missing a .
before See
.
doc/changelog.rst
Outdated
:class:`bson.codec_options.CodecOptions`'s ``datetime_conversion`` | ||
parameter for more details (`PYTHON-1824`_). | ||
- Added support for using a :class:`~pymongo.mongo_client.MongoClient` after | ||
a ``fork()`` (`PYTHON-2484`_). |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
fork() ->
:py:func:`os.fork`
Also updated the FAQ for the fork safety section.