Skip to content

Automation: Update uv.lock - #2996

Merged
sleepyStick merged 2 commits into
mainfrom
uv-lock-update
Aug 17, 2026
Merged

sleepyStick merged 2 commits into
mainfrom
uv-lock-update

Conversation

@mongodb-drivers-pr-bot

@mongodb-drivers-pr-bot mongodb-drivers-pr-bot Bot commented Aug 17, 2026 •

Copy link
Copy Markdown
Contributor

Updated packages

  • backports-zstd: 1.3.0, 1.6.0 → 1.3.0, 1.7.0
  • boto3: 1.42.97, 1.43.57 → 1.42.97, 1.43.72
  • botocore: 1.42.97, 1.43.57 → 1.42.97, 1.43.72
  • cffi: 2.0.0, 2.1.0 → 2.0.0, 2.1.1
  • charset-normalizer: 3.4.9 → 3.5.1
  • cryptography: 47.0.0, 49.0.0 → 47.0.0, 50.0.0
  • gevent: 26.7.0 → 26.7.0, 26.8.0
  • greenlet: 3.2.5, 3.5.4 → 3.2.5, 3.5.5
  • jmespath: 0.10.0, 1.1.0 → 1.1.0
  • librt: 0.13.0 → 0.15.0
  • packaging: 26.2 → 26.3
  • pip: 26.0.1, 26.1.2 → 26.0.1, 26.2.1
  • pygments: 2.20.0 → 2.21.0
  • pyopenssl: 26.2.0, 26.3.0 → 26.2.0, 26.4.0
  • setuptools: 82.0.1, 83.0.0 → 82.0.1, 84.0.0
  • soupsieve: 2.8.4, 2.9.1 → 2.8.4, 2.9.2
  • starlette: 0.49.3, 1.3.1 → 0.49.3, 1.6.0
  • uvicorn: 0.39.0, 0.51.0 → 0.39.0, 0.52.3
  • websockets: 15.0.1, 16.1.1 → 15.0.1, 16.1.1, 17.0.1

PYTHON-6032: OCSP fix required by the cryptography bump

PYTHON-6032 rides along here because it has to land with the bump: cryptography 50.0.0 breaks without it, and it has nothing to prove without the new lock.

cryptography 50.0.0 added ML-KEM keys to what Certificate.public_key() returns. ML-KEM is a key encapsulation mechanism with no verify(), so OCSP signature verification raised AttributeError instead of returning a result. It now fails closed, since such a key cannot have produced a signature and reporting it valid would be wrong.

The fix also widens the hand-maintained public-key union, which had drifted narrower than public_key(). That drift is what the static and Typing Tests jobs were reporting on every branch resolving cryptography 50.

Verified with the lock file in this PR: mypy passes, as it does against cryptography 47.0.0, the declared minimum. test_ocsp_support.py goes from 57 to 59 passing, the delta being regression tests for both ML-KEM key sizes.

@mongodb-drivers-pr-bot
mongodb-drivers-pr-bot Bot requested a review from a team as a code owner August 17, 2026 20:25
@mongodb-drivers-pr-bot mongodb-drivers-pr-bot Bot added the dependencies Pull requests that update a dependency file label Aug 17, 2026
cryptography 50.0.0 added MLKEM768PublicKey and MLKEM1024PublicKey to the
return type of Certificate.public_key(). ML-KEM is a key encapsulation
mechanism, so those keys have no verify(), and _verify_signature reached its
generic branch and raised AttributeError instead of reporting a result.

Such a key cannot have produced a signature, so verification now fails closed
and returns 0 rather than treating the signature as valid.

The hand-maintained CertificateIssuerPublicKeyTypes union gains the same two
types, which is what mypy was reporting: the union had drifted narrower than
public_key(). cryptography exports no public alias to track instead, so the
union is spelled out and carries a comment saying what it must follow. This is
the same drift PYTHON-5915 fixed for ML-DSA.
@blink1073

Copy link
Copy Markdown
Member

@sleepyStick I manually ran the uv lock workflow because the cryptography 50.0 typing failures were showing up in my otel branches. I pushed a fix for PYTHON-6032 directly to this branch.

@codecov

codecov Bot commented Aug 17, 2026

Copy link
Copy Markdown

Codecov Report

✅ All modified and coverable lines are covered by tests.

📢 Thoughts on this report? Let us know!

@sleepyStick
sleepyStick merged commit 8ce629a into main Aug 17, 2026
85 of 90 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

dependencies Pull requests that update a dependency file

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants