Added supported for the contextvars module. Specifically, it is now possible to access context variables inside ~pymongo.monitoring.CommandListener callbacks.
Bug-fixes:
Fixed a bug that prohibited users from subclassing the motor.motor_asyncio.AsyncIOMotorClient, motor.motor_asyncio.AsyncIOMotorDatabase, and motor.motor_asyncio.AsyncIOMotorCollection classes.
Updated the documentation to indicate full support for Windows. Previously, the documentation stated that Windows support was experimental.
Motor 2.2 adds support for MongoDB 4.4 features. It depends on PyMongo 3.11 or later. Motor continues to support MongoDB 3.0 and later. Motor 2.2 also drops support for Python 2.7 and Python 3.4.
New features:
Added the AsyncIOMotorCursor method ~motor.motor_asyncio.AsyncIOMotorCursor.next that advances the cursor one document at a time, similar to to the AsyncIOMotorChangeStream method ~motor.motor_asyncio.AsyncIOMotorChangeStream.next.
Added index-hinting support to the ~motor.motor_asyncio.AsyncIOMotorCollection.replace_one, ~motor.motor_asyncio.AsyncIOMotorCollection.update_one, ~motor.motor_asyncio.AsyncIOMotorCollection.update_many, ~motor.motor_asyncio.AsyncIOMotorCollection.delete_one, ~motor.motor_asyncio.AsyncIOMotorCollection.delete_many, ~motor.motor_asyncio.AsyncIOMotorCollection.find_one_and_replace, ~motor.motor_asyncio.AsyncIOMotorCollection.find_one_and_update, and ~motor.motor_asyncio.AsyncIOMotorCollection.find_one_and_delete methods.
Added support for the allow_disk_use parameter to ~motor.motor_asyncio.AsyncIOMotorCollection.find.
Modified the ~motor.motor_asyncio.AsyncIOMotorChangeStream class' async context manager such that the change stream cursor is now created during the call to async with. Previously, the cursor was only created when the application iterated the ~motor.motor_asyncio.AsyncIOMotorChangeStream object which could result in the application missing some changes.
Motor now advertises the framework used by the application to the MongoDB server as asyncio or Tornado. Previously, no framework information was reported if the application used asyncio.
Bug-fixes:
Fixed a bug that caused calls to the ~motor.motor_asyncio.AsyncIOMotorGridOut.open() method to raise AttributeError.
Fixed a bug that sometimes caused ~asyncio.Future.set_result to be called on a cancelled ~asyncio.Future when iterating a ~motor.motor_asyncio.AsyncIOMotorCommandCursor.
Deprecations:
Deprecated AsyncIOMotorCursor method ~motor.motor_asyncio.AsyncIOMotorCursor.next_object and property ~motor.motor_asyncio.AsyncIOMotorCursor.fetch_next. Applications should use async for to iterate over cursors instead.
Deprecated the ~motor.motor_asyncio.AsyncIOMotorClient.fsync method. Applications should run the fsync command directly with ~motor.motor_asyncio.AsyncIOMotorDatabase.command instead.
Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.
Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR:
- `@dependabot rebase` will rebase this PR
- `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it
- `@dependabot merge` will merge this PR after your CI passes on it
- `@dependabot squash and merge` will squash and merge this PR after your CI passes on it
- `@dependabot cancel merge` will cancel a previously requested merge and block automerging
- `@dependabot reopen` will reopen this PR if it is closed
- `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
- `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
- `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
- `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language
- `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language
- `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language
- `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language
- `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme
Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com):
- Update frequency (including time of day and day of week)
- Pull request limits (per update run and/or open at any time)
- Out-of-range updates (receive only lockfile updates, if desired)
- Security updates (receive only security updates, if desired)
Bumps motor from 2.2.0 to 2.3.0.
Release notes
Sourced from motor's releases.
Changelog
Sourced from motor's changelog.
Commits
c3e51f8
BUMP 2.3.0 (#93)6f7ced5
Document Motor release process (#92)cd8c47a
MOTOR-591 Document that Windows is supported (#91)ed02ce5
MOTOR-614 Use Python 3 syntax for super() calls (#89)ca6141c
MOTOR-613 Test contextvars support (#90)e2d0e18
MOTOR-613 Add contextvars support (#88)5053f21
BUMP 2.3.0.dev0 (#87)ed7a0a2
BUMP 2.2.0 (#86)fad6881
MOTOR-589 Fix synchrotest failures (#67)Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting
@dependabot rebase
.Dependabot commands and options
You can trigger Dependabot actions by commenting on this PR: - `@dependabot rebase` will rebase this PR - `@dependabot recreate` will recreate this PR, overwriting any edits that have been made to it - `@dependabot merge` will merge this PR after your CI passes on it - `@dependabot squash and merge` will squash and merge this PR after your CI passes on it - `@dependabot cancel merge` will cancel a previously requested merge and block automerging - `@dependabot reopen` will reopen this PR if it is closed - `@dependabot close` will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually - `@dependabot ignore this major version` will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this minor version` will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself) - `@dependabot ignore this dependency` will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself) - `@dependabot use these labels` will set the current labels as the default for future PRs for this repo and language - `@dependabot use these reviewers` will set the current reviewers as the default for future PRs for this repo and language - `@dependabot use these assignees` will set the current assignees as the default for future PRs for this repo and language - `@dependabot use this milestone` will set the current milestone as the default for future PRs for this repo and language - `@dependabot badge me` will comment on this PR with code to add a "Dependabot enabled" badge to your readme Additionally, you can set the following in your Dependabot [dashboard](https://app.dependabot.com): - Update frequency (including time of day and day of week) - Pull request limits (per update run and/or open at any time) - Out-of-range updates (receive only lockfile updates, if desired) - Security updates (receive only security updates, if desired)