Visitar URL original
PYTHON-6138 Drop Python 3.9 and 3.10 Support by aclark4life · Pull Request #3104 · mongodb/mongo-python-driver · GitHub
Skip to content

PYTHON-6138 Drop Python 3.9 and 3.10 Support - #3104

Draft
aclark4life wants to merge 2 commits into
mongodb:mainfrom
aclark4life:PYTHON-6138-drop-py39-py310
Draft

aclark4life wants to merge 2 commits into
mongodb:mainfrom
aclark4life:PYTHON-6138-drop-py39-py310

Conversation

@aclark4life

@aclark4life aclark4life commented Oct 7, 2026 •

Copy link
Copy Markdown
Contributor

PYTHON-6138

Changes in this PR

  • Raise requires-python to >=3.11.
  • Drop Python 3.9/3.10 from GitHub Actions matrices.
  • Drop Python 3.10 from the Evergreen CPYTHONS matrix and 3.9/PyPy 3.9/PyPy 3.10 from MIN_SUPPORT_VERSIONS.
    • Regenerate .evergreen/generated_configs/.
  • Regenerate uv.lock.
  • Update README and changelog.

Test Plan

  • GitHub Actions static, build, test_minimum, test_sdist jobs pass on 3.11.
  • Evergreen patch run of regenerated config.

Checklist

Checklist for Author

  • Did you update the changelog (if necessary)?
  • Is the intention of the code captured in relevant tests?
  • If there are new TODOs, has a related JIRA ticket been created?

Checklist for Reviewer

  • Does the title of the PR reference a JIRA Ticket?
  • Do you fully understand the implementation? (Would you be comfortable explaining how this code works to someone else?)
  • Have you checked for spelling & grammar errors?
  • Is all relevant documentation (README or docstring) updated?

Copilot AI left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

🟡 Changes recommended

Evergreen still defaults and pins some jobs to Python 3.10, which conflicts with the new package requirement.

3 open findings
What changed in this PR

Raises PyMongo’s minimum supported runtime to Python 3.11 and aligns packaging, CI, Evergreen, and documentation.

Changes:

  • Sets requires-python to 3.11+ and regenerates dependencies.
  • Removes Python 3.9/3.10 from CI and distribution jobs.
  • Updates Evergreen matrices and release documentation.
File Description
README.md Updates supported versions.
pyproject.toml Raises the Python floor and removes classifiers.
uv.lock Regenerates dependencies for Python 3.11+.
doc/​changelog.rst Announces dropped runtime support.
.github/​workflows/​uv-lock-update.yml Uses Python 3.11 for lock updates.
.github/​workflows/​test-python.yml Updates test jobs to Python 3.11+.
.github/​workflows/​sbom.yml Uses Python 3.11 for SBOM generation.
.github/​workflows/​dist.yml Drops 3.9/3.10 wheel assertions.
.evergreen/​scripts/​generate_config_utils.py Updates Evergreen interpreter matrices.
.evergreen/​generated_configs/​tasks.yml Regenerates Evergreen tasks.

🧠 Review effort: Balanced


💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.


ALL_VERSIONS = ["4.4", "5.0", "6.0", "7.0", "8.0", "9.0", "rapid", "latest"]
CPYTHONS = ["3.10", "3.11", "3.12", "3.13", "3.14t", "3.14", "3.15t", "3.15"]
CPYTHONS = ["3.11", "3.12", "3.13", "3.14t", "3.14", "3.15t", "3.15"]
Comment thread README.md
## Dependencies

PyMongo supports CPython 3.9+ and PyPy3.9+. PyPy support is deprecated and will be removed in a future release.
PyMongo supports CPython 3.11+ and PyPy3.11+. PyPy support is deprecated and will be removed in a future release.
Comment thread pyproject.toml
Comment on lines +57 to +58
# AWS task runs on pre-3.10 interpreters; this keeps both forks on current
# releases.

This branch has not been deployed

No deployments
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants