Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
74c011f
PYTHON-5862 Cleanup lockless uv usage (#2966)
NoahStapp Jul 31, 2026
70573fe
PYTHON-5930 Fix SSL_CERT_FILE/SSL_CERT_DIR trust store handling (#2965)
blink1073 Aug 3, 2026
e504eb6
PYTHON-5974 Loosen baseBackoffMS prose test timing (#2967)
NoahStapp Aug 3, 2026
4efdc82
PYTHON-5724 Add integration test exercising compression logic (#2935)
aclark4life Aug 4, 2026
6742037
PYTHON-5977 APM/logging hot-path optimizations (#2968)
NoahStapp Aug 5, 2026
d03d621
PYTHON-5974 - Fix Python 3.12 check for overload test bounds (#2978)
NoahStapp Aug 5, 2026
2d2daed
PYTHON-5980 Commit uv.lock and automate weekly updates (#2977)
blink1073 Aug 12, 2026
0e99c46
Bump the actions group across 1 directory with 4 updates (#2969)
dependabot[bot] Aug 12, 2026
a1243ef
PYTHON-6001 Pin mockupdb to a released version instead of the master …
blink1073 Aug 13, 2026
e532774
PYTHON-6006 Add MongoDB 9.0 to the Evergreen test matrix (#2986)
blink1073 Aug 13, 2026
3b43d40
PYTHON-5980 Update exclude-newer docs for the uv-lock-update action (…
blink1073 Aug 17, 2026
d961729
PYTHON-4008 Support exhaust cursors on mongos 7.1+ (#2985)
carsontung666 Aug 17, 2026
c37efd5
PYTHON-5805 Split TLS wrapping out of configured socket helpers
blink1073 Aug 17, 2026
967f17a
PYTHON-5805 Add KMSConnectContext and AutoEncryptionOpts.kms_connect_…
blink1073 Aug 17, 2026
38ecefc
PYTHON-5805 Route KMS connections through kms_connect_callback
blink1073 Aug 17, 2026
8c24872
PYTHON-5805 Add kms_connect_callback to ClientEncryption
blink1073 Aug 17, 2026
84c76a2
PYTHON-5805 Fix sync ClientEncryption docstring to say 'regular funct…
blink1073 Aug 18, 2026
0b1f785
PYTHON-5805 Add synchro tripwire for kms_connect_callback docstring m…
blink1073 Aug 18, 2026
6f2b0e1
PYTHON-5805 Add prose tests for KMS connect callback
blink1073 Aug 18, 2026
516b267
PYTHON-5805 Fix KMSConnectContext.timeout docstring and document case…
blink1073 Aug 18, 2026
640b991
PYTHON-5805 Add changelog entry for kms_connect_callback
blink1073 Aug 18, 2026
9c1c544
PYTHON-5805 Guard async callback contract and fix proxy example docs
blink1073 Aug 18, 2026
93c1445
PYTHON-5805 Skip prose case 5 as a known CSOT spec discrepancy
blink1073 Aug 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,167 changes: 803 additions & 364 deletions .evergreen/generated_configs/tasks.yml

Large diffs are not rendered by default.

15 changes: 14 additions & 1 deletion .evergreen/generated_configs/variants.yml
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,7 @@ buildvariants:
- name: .test-non-standard .server-6.0 .sharded_cluster-auth-ssl
- name: .test-non-standard .server-7.0 .sharded_cluster-auth-ssl
- name: .test-non-standard .server-8.0 .sharded_cluster-auth-ssl
- name: .test-non-standard .server-9.0 .sharded_cluster-auth-ssl
- name: .test-non-standard .server-rapid .sharded_cluster-auth-ssl
- name: .test-non-standard .server-latest .sharded_cluster-auth-ssl
display_name: Load Balancer
Expand Down Expand Up @@ -467,7 +468,7 @@ buildvariants:
- name: .test-standard !.pypy .async .replica_set-noauth-ssl
display_name: PyOpenSSL macOS
run_on:
- rhel87-small
- macos-14
batchtime: 1440
expansions:
SUB_TEST_NAME: pyopenssl
Expand Down Expand Up @@ -545,6 +546,15 @@ buildvariants:
expansions:
VERSION: "8.0"
tags: [coverage_tag]
- name: mongodb-v9.0
tasks:
- name: .server-version
display_name: "* MongoDB v9.0"
run_on:
- rhel87-small
expansions:
VERSION: "9.0"
tags: [coverage_tag]
- name: mongodb-rapid
tasks:
- name: .server-version
Expand Down Expand Up @@ -582,6 +592,7 @@ buildvariants:
- name: .test-standard !.replica_set-noauth-ssl .server-6.0
- name: .test-standard !.replica_set-noauth-ssl .server-7.0
- name: .test-standard !.replica_set-noauth-ssl .server-8.0
- name: .test-standard !.replica_set-noauth-ssl .server-9.0
- name: .test-standard !.replica_set-noauth-ssl .server-rapid
- name: .test-standard !.replica_set-noauth-ssl .server-latest
display_name: Stable API require v1 RHEL8 Auth
Expand All @@ -598,6 +609,7 @@ buildvariants:
- name: .test-standard .server-6.0 .standalone-noauth-nossl
- name: .test-standard .server-7.0 .standalone-noauth-nossl
- name: .test-standard .server-8.0 .standalone-noauth-nossl
- name: .test-standard .server-9.0 .standalone-noauth-nossl
- name: .test-standard .server-rapid .standalone-noauth-nossl
- name: .test-standard .server-latest .standalone-noauth-nossl
display_name: Stable API accept v2 RHEL8 Auth
Expand All @@ -621,6 +633,7 @@ buildvariants:
- name: .test-standard !.pypy .server-6.0
- name: .test-standard !.pypy .server-7.0
- name: .test-standard !.pypy .server-8.0
- name: .test-standard !.pypy .server-9.0
- name: .test-standard !.pypy .server-rapid
- name: .test-standard !.pypy .server-latest
display_name: "* Test macOS Arm64"
Expand Down
8 changes: 3 additions & 5 deletions .evergreen/run-mongodb-aws-ecs-test.sh
Original file line number Diff line number Diff line change
Expand Up @@ -19,15 +19,13 @@ fi
# Now we can safely enable xtrace
set -o xtrace

# Install a c compiler.
# Install a C compiler (for the C extensions) and git (needed by uv to
# resolve the mockupdb git dependency)
apt-get -qq update < /dev/null > /dev/null
apt-get -q install -y build-essential
apt-get -q install -y build-essential git

export SET_XTRACE_ON=1
export CI=true
# This container has no git, so uv must never try to resolve the mockupdb
# git dependency; UV_NO_LOCK makes uv ignore any lock file entirely.
export UV_NO_LOCK=1
cd src
rm -rf .venv
rm -f .evergreen/scripts/test-env.sh || true
Expand Down
2 changes: 0 additions & 2 deletions .evergreen/run-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ else
fi

# Start the test runner.
# Never create or read a uv.lock; hosts without git can't resolve mockupdb.
export UV_NO_LOCK=1
echo "Running tests with UV_PYTHON=${UV_PYTHON:-}..."
echo "UV_ARGS=${UV_ARGS}"
uv run ${UV_ARGS} --reinstall-package pymongo .evergreen/scripts/run_tests.py "$@"
Expand Down
1 change: 0 additions & 1 deletion .evergreen/scripts/configure-env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,6 @@ export CARGO_HOME="$CARGO_HOME"
export UV_TOOL_DIR="$UV_TOOL_DIR"
export UV_CACHE_DIR="$UV_CACHE_DIR"
export UV_TOOL_BIN_DIR="$DRIVERS_TOOLS_BINARIES"
export UV_NO_LOCK=1
export PYMONGO_BIN_DIR="$PYMONGO_BIN_DIR"
export PATH="$PATH_EXT"
# shellcheck disable=SC2154
Expand Down
1 change: 1 addition & 0 deletions .evergreen/scripts/generate_config.py
Original file line number Diff line number Diff line change
Expand Up @@ -251,6 +251,7 @@ def create_pyopenssl_variants():
create_variant(
tasks,
display_name,
host=host,
expansions=expansions,
batchtime=batchtime,
)
Expand Down
2 changes: 1 addition & 1 deletion .evergreen/scripts/generate_config_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@
# Globals
##############

ALL_VERSIONS = ["4.2", "4.4", "5.0", "6.0", "7.0", "8.0", "rapid", "latest"]
ALL_VERSIONS = ["4.2", "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"]
PYPYS = ["pypy3.11"]
MIN_SUPPORT_VERSIONS = ["3.9", "pypy3.9", "pypy3.10"]
Expand Down
10 changes: 4 additions & 6 deletions .evergreen/scripts/kms_tester.py
Original file line number Diff line number Diff line change
Expand Up @@ -33,9 +33,7 @@ def _setup_azure_vm(base_env: dict[str, str]) -> None:
env["AZUREKMS_CMD"] = "sudo apt-get install -y python3-dev build-essential"
run_command(f"{azure_dir}/run-command.sh", env=env)

env["AZUREKMS_CMD"] = (
"CI=true UV_NO_LOCK=1 bash .evergreen/just.sh setup-tests kms azure-remote"
)
env["AZUREKMS_CMD"] = "CI=true bash .evergreen/just.sh setup-tests kms azure-remote"
run_command(f"{azure_dir}/run-command.sh", env=env)
LOGGER.info("Setting up Azure VM... done.")

Expand All @@ -55,7 +53,7 @@ def _setup_gcp_vm(base_env: dict[str, str]) -> None:
env["GCPKMS_CMD"] = "sudo apt-get install -y python3-dev build-essential"
run_command(f"{gcp_dir}/run-command.sh", env=env)

env["GCPKMS_CMD"] = "CI=true UV_NO_LOCK=1 bash ./.evergreen/just.sh setup-tests kms gcp-remote"
env["GCPKMS_CMD"] = "CI=true bash ./.evergreen/just.sh setup-tests kms gcp-remote"
run_command(f"{gcp_dir}/run-command.sh", env=env)
LOGGER.info("Setting up GCP VM...")

Expand Down Expand Up @@ -132,10 +130,10 @@ def test_kms_send_to_remote(sub_test_name: str) -> None:
key_name = os.environ["KEY_NAME"]
key_vault_endpoint = os.environ["KEY_VAULT_ENDPOINT"]
env["AZUREKMS_CMD"] = (
f'KEY_NAME="{key_name}" KEY_VAULT_ENDPOINT="{key_vault_endpoint}" CI=true UV_NO_LOCK=1 bash ./.evergreen/just.sh run-tests'
f'KEY_NAME="{key_name}" KEY_VAULT_ENDPOINT="{key_vault_endpoint}" CI=true bash ./.evergreen/just.sh run-tests'
)
else:
env["GCPKMS_CMD"] = "CI=true UV_NO_LOCK=1 ./.evergreen/just.sh run-tests"
env["GCPKMS_CMD"] = "CI=true ./.evergreen/just.sh run-tests"
cmd = f"{DIRS[sub_test_name]}/run-command.sh"
run_command(cmd, env=env)

Expand Down
3 changes: 0 additions & 3 deletions .evergreen/scripts/setup-tests.sh
Original file line number Diff line number Diff line change
Expand Up @@ -21,9 +21,6 @@ if [ -f $SCRIPT_DIR/env.sh ]; then
source $SCRIPT_DIR/env.sh
fi

# Never create or read a uv.lock; hosts without git can't resolve mockupdb.
export UV_NO_LOCK=1

echo "Setting up tests with args \"$*\"..."
uv run ${USE_ACTIVE_VENV:+--active} "$SCRIPT_DIR/setup_tests.py" "$@"
echo "Setting up tests with args \"$*\"... done."
18 changes: 0 additions & 18 deletions .github/actions/set-uv-exclude-newer/action.yml

This file was deleted.

7 changes: 4 additions & 3 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,10 +11,11 @@ updates:
actions:
patterns:
- "*"
# Python (uv)
# Python (uv). Routine version updates are handled by the uv-lock-update
# workflow, so a limit of 0 turns off Dependabot version-update PRs here.
# Security updates are exempt from this limit and still open normally.
- package-ecosystem: "uv"
directory: "/"
schedule:
interval: "weekly"
cooldown:
default-days: 7
open-pull-requests-limit: 0
4 changes: 2 additions & 2 deletions .github/workflows/dist.yml
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@
persist-credentials: false
ref: ${{ inputs.ref }}

- uses: actions/setup-python@v6.3.0
- uses: actions/setup-python@v7.0.0
with:
cache: 'pip'
python-version: 3.11
Expand Down Expand Up @@ -111,7 +111,7 @@
persist-credentials: false
ref: ${{ inputs.ref }}

- uses: actions/setup-python@v6.3.0
- uses: actions/setup-python@v7.0.0
with:
# Build sdist on lowest supported Python
python-version: "3.9"
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/release-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
path: dist/
- name: Publish package distributions to PyPI
if: startsWith(env.DRY_RUN, 'false')
uses: pypa/gh-action-pypi-publish@cef221092ed1bacb1cc03d23a2d87d1d172e277b # release/v1
uses: pypa/gh-action-pypi-publish@dc37677b2e1c63e2034f94d8a5b11f265b73ba33 # release/v1

post-publish:
needs: [publish]
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/sbom.yml
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ jobs:
persist-credentials: false

- name: Set up Python
uses: actions/setup-python@v6.3.0
uses: actions/setup-python@v7.0.0
with:
python-version: "3.10"

Expand Down
36 changes: 15 additions & 21 deletions .github/workflows/test-python.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,9 +17,6 @@ defaults:
permissions:
contents: read

env:
UV_NO_LOCK: "1"

jobs:

static:
Expand All @@ -28,12 +25,16 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "3.10"
# Runs before the install so a stale lock fails in seconds rather than
# after the build and typecheck.
- name: Check lockfile is up to date
run: |
uv lock --check
- name: Install just
run: uv tool install rust-just
- name: Install Python dependencies
Expand Down Expand Up @@ -81,9 +82,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
Expand All @@ -104,9 +104,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "3.10"
Expand All @@ -133,9 +132,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "3.10"
Expand All @@ -159,9 +157,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "3.10"
Expand All @@ -182,9 +179,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "${{matrix.python}}"
Expand All @@ -204,9 +200,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
enable-cache: true
python-version: "3.10"
Expand Down Expand Up @@ -235,7 +230,7 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: actions/setup-python@v6.3.0
- uses: actions/setup-python@v7.0.0
with:
cache: 'pip'
cache-dependency-path: 'pyproject.toml'
Expand Down Expand Up @@ -269,7 +264,7 @@ jobs:
mkdir test
tar --strip-components=1 -zxf *.tar.gz -C ./test
ls test
- uses: actions/setup-python@v6.3.0
- uses: actions/setup-python@v7.0.0
with:
cache: 'pip'
cache-dependency-path: 'sdist/test/pyproject.toml'
Expand All @@ -295,9 +290,8 @@ jobs:
- uses: actions/checkout@v7.0.1
with:
persist-credentials: false
- uses: ./.github/actions/set-uv-exclude-newer
- name: Install uv
uses: astral-sh/setup-uv@11f9893b081a58869d3b5fccaea48c9e9e46f990 # v8.3.2
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
python-version: "3.9"
- id: setup-mongodb
Expand Down
42 changes: 42 additions & 0 deletions .github/workflows/uv-lock-update.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,42 @@
name: uv Lock Update

on:
schedule:
# Tuesdays at 12:00 UTC.
- cron: "0 12 * * 2"
workflow_dispatch:
inputs:
dry_run:
description: "Run without pushing or opening a pull request"
type: boolean
default: false

permissions:
contents: read
# A live run uses the app token, but a dry run looks up the existing pull
# request with github.token, so that read has to be granted here.
pull-requests: read

concurrency:
group: uv-lock-update
cancel-in-progress: false

jobs:
update:
name: Update uv.lock
runs-on: ubuntu-latest
environment: automation
if: github.repository_owner == 'mongodb' || github.event_name == 'workflow_dispatch'
steps:
- uses: actions/checkout@3d3c42e5aac5ba805825da76410c181273ba90b1 # v7.0.1
with:
persist-credentials: false
- name: Install uv
uses: astral-sh/setup-uv@c771a70e6277c0a99b617c7a806ffedaca235ff9 # v9.0.0
with:
python-version: "3.10"
- uses: mongodb-labs/drivers-github-tools/python/uv-lock-update@bc33fb6aca874b4c37a4ee79bc7061a1ee68baad # v3
with:
app_id: ${{ vars.APP_ID }}
private_key: ${{ secrets.APP_PRIVATE_KEY }}
dry_run: ${{ inputs.dry_run || 'false' }}
2 changes: 1 addition & 1 deletion .github/workflows/zizmor.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,4 +18,4 @@ jobs:
with:
persist-credentials: false
- name: Run zizmor 🌈
uses: zizmorcore/zizmor-action@6599ee8b7a49aef6a770f63d261d214911a7ce02 # v0.6.0
uses: zizmorcore/zizmor-action@3dc1ecc9bcb9e94e9b2c709687979e1298497054 # v0.6.2
Loading
Loading