fix(python): pin python version and add uv caching#3690
Open
slbotbm wants to merge 3 commits into
Open
Conversation
ethanlin01x
reviewed
Jul 17, 2026
Contributor
Author
|
/ready |
ryankert01
reviewed
Jul 19, 2026
ryankert01
left a comment
Member
There was a problem hiding this comment.
We can add these 3 .python-version files to current sync check (sync-python-interpreter-version.sh) so precommit would detect version inconsistencies if we upgrade at somewhere.
Contributor
Author
|
@ryankert01 updated, thanks for the reminder. |
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.
While working on the python sdk, often
uv sync --all-extrasdoes not actually recreate the .so file using the latest changes and leaves the old version of the sdk, leading to difficulties in actually testing it on local. This change adds explicit cache keys for files. If the files are changed, the .so extension is automatically rebuilt on runninguv sync --all-extras. (caveat: it will also be run when running other commands likeuv run ruff formatsince there is a hidden sync step in these commands).I also pin the python version to 3.10 explicitly. Previously, we only declare the python version to be >= 3.10, which led to uv downloading python according to the following hierarchy:
By pinning the version, we force uv to utilize 3.10.