PYTHON-6084 Rework Evergreen Python interpreter selection for uv - #26
Draft
blink1073 wants to merge 16 commits into
Draft
PYTHON-6084 Rework Evergreen Python interpreter selection for uv#26blink1073 wants to merge 16 commits into
blink1073 wants to merge 16 commits into
Conversation
blink1073
commented
Sep 10, 2026
…oolchain export
blink1073
commented
Sep 11, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Rework how Evergreen and GitHub Actions select the Python interpreter and pin the uv binary. Task config now sets
UV_PYTHONdirectly (a version like3.10/3.14t, an implementation likepypy3.11, or an absolute path) so the interpreter lookup happens on the host. The uv binary version is pinned once inpyproject.tomlvia[tool.uv] required-version.UV_PYTHONdirectly; removedTOOLCHAIN_VERSIONeverywhere and regenerated the Evergreen task and variant configs.setup-uv-python.shresolves the interpreter on the host, settingUV_PYTHON_SEARCH_PATHandUV_PYTHON_PREFERENCEagainst a matching toolchain Python, and defaults to CPython 3.10 when a task does not pin one.[tool.uv] required-versioninpyproject.toml(==0.12.12) as a single source: uv enforces it locally,astral-sh/setup-uvreads it on GitHub, and Evergreen reads it too. Bumped manually.PYMONGO_BIN_DIRis${TMPDIR:-/tmp}/pymongo-binso the pinned uv stays isolated from the drivers-tools bin dir, and it is placed before that dir on PATH.just installinstalls the pinned uv into$HOME/.local/bin, and the justfile puts that directory first on PATH as a backstop.PYTHON-6084
Changes in this PR
Test Plan
Checklist
Checklist for Author
Checklist for Reviewer