feat: replace pip with uv for 60% faster integration tests #495
+73
−45
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.
Overview
This PR migrates our integration test pipelines from
piptouv, reducing installation time by ~60% and significantly improving dependency resolution stability.Changes
integration.cloudbuild.yamlfor all packages (toolbox-core,toolbox-adk,toolbox-langchain,toolbox-llamaindex) to useuvand persistent virtual environments.typing-extensions>=4.12.2intoolbox-adkto resolve a conflict masked bypipbut caught byuv's stricter resolver.Note
This PR does not only speeds up CI but also provides the resolution capabilities needed for upcoming Python 3.14 support (#494).
Problem
There were 2 problems that occur with adding Python 3.14 without
uv:pipeventually backtracks to ancient versions of libraries. These older versions contain C-extensions that are fundamentally incompatible with the Python 3.14 C API, causing build failures:Solution
uv's resolver is significantly faster and correctly navigates the dependency graph without excessive backtracking, essentially forcing the resolver to pick newer, compatible source distributions instead of falling back to broken legacy versions. This prevents the build from hanging and ensures we install versions ofpydantic-core(2.41+) that actually compile on Python 3.14.