Adopt uv for Python dependency management (#286)#311
Conversation
Replace pip with uv across Docker builds and CI for faster, reproducible installs. pyproject.toml + uv.lock become the single source of truth, eliminating the duplicate requirements.txt files. - Generate uv.lock from pyproject.toml - Update production Dockerfile to use uv (binary removed before final stage) - Update test Dockerfile to use uv with --group test - Replace pip install with uv pip install --system in all CI jobs - Add astral-sh/setup-uv@v6 action to CI - Delete requirements.txt and requirements-test.txt Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
Warning Rate limit exceeded
⌛ How to resolve this issue?After the wait time has elapsed, a review can be triggered using the We recommend that you space out your commits to avoid hitting the rate limit. 🚦 How do rate limits work?CodeRabbit enforces hourly rate limits for each developer per organization. Our paid plans have higher rate limits than the trial, open-source and free plans. In all cases, we re-allow further reviews after a brief timeout. Please see our FAQ for further information. ℹ️ Review info⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Run ID: 📒 Files selected for processing (3)
📝 WalkthroughWalkthroughThis PR adopts Changes
Estimated code review effort🎯 3 (Moderate) | ⏱️ ~20 minutes Possibly related issues
Possibly related PRs
Poem
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
There was a problem hiding this comment.
Actionable comments posted: 2
🤖 Prompt for all review comments with AI agents
Verify each finding against the current code and only fix it if needed.
Inline comments:
In @.github/workflows/ci.yml:
- Around line 56-57: Update the GitHub Actions step that configures uv to use
the latest released version: replace the uses reference "astral-sh/setup-uv@v6"
with the latest tag "astral-sh/setup-uv@v7.6.0" in the CI workflow; ensure any
inputs or outputs expected by the new action version (the step named "Set up
uv") remain compatible and adjust call parameters if needed.
In `@src/docker/build/docker-image/Dockerfile`:
- Line 19: The Dockerfile currently copies from the floating image tag
"ghcr.io/astral-sh/uv:latest" which undermines reproducible builds; update the
COPY line to reference a pinned uv tag (or introduce a build ARG like UV_TAG and
default it to a specific version such as "ghcr.io/astral-sh/uv:0.10.x") so the
COPY --from source is deterministic—change the COPY --from reference (the line
containing COPY --from=ghcr.io/astral-sh/uv:latest /uv /usr/local/bin/uv) to use
the chosen pinned tag or an ARG-based pinned value.
ℹ️ Review info
⚙️ Run configuration
Configuration used: Path: .coderabbit.yaml
Review profile: ASSERTIVE
Plan: Pro
Run ID: a847998e-6eb3-446d-9393-ad2c331e9105
⛔ Files ignored due to path filters (1)
src/python/uv.lockis excluded by!**/*.lock
📒 Files selected for processing (5)
.github/workflows/ci.ymlsrc/docker/build/docker-image/Dockerfilesrc/docker/build/test-image/Dockerfilesrc/python/requirements-test.txtsrc/python/requirements.txt
💤 Files with no reviewable changes (2)
- src/python/requirements-test.txt
- src/python/requirements.txt
.github/workflows/ci.yml
Outdated
| - name: Set up uv | ||
| uses: astral-sh/setup-uv@v6 |
There was a problem hiding this comment.
🧩 Analysis chain
🌐 Web query:
astral-sh/setup-uv GitHub action latest version
💡 Result:
The latest version of the astral-sh/setup-uv GitHub Action is v7.6.0, released on March 16, 2026.
Citations:
- 1: https://github.com/astral-sh/setup-uv/releases
- 2: https://github.com/astral-sh/setup-uv
- 3: https://github.com/marketplace/actions/astral-sh-setup-uv
Update setup-uv action to the latest version.
The workflow currently uses astral-sh/setup-uv@v6, but the latest version is v7.6.0. Update to the latest version to benefit from new features and security patches.
🤖 Prompt for AI Agents
Verify each finding against the current code and only fix it if needed.
In @.github/workflows/ci.yml around lines 56 - 57, Update the GitHub Actions
step that configures uv to use the latest released version: replace the uses
reference "astral-sh/setup-uv@v6" with the latest tag
"astral-sh/setup-uv@v7.6.0" in the CI workflow; ensure any inputs or outputs
expected by the new action version (the step named "Set up uv") remain
compatible and adjust call parameters if needed.
- Bump astral-sh/setup-uv from v6 to v7 (latest major) in CI - Pin Dockerfile COPY --from to ghcr.io/astral-sh/uv:0.11 instead of :latest for reproducible builds Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Summary
pyproject.toml+uv.lockbecome the single source of truth, eliminating the duplicaterequirements.txt/requirements-test.txtfilesChanges
Docker
COPY --from=ghcr.io/astral-sh/uv:latestinto python-deps stage,uv pip install --system --no-cache --strict -r pyproject.toml, binary removed after install--group testto include test dependenciesCI (
ci.yml)astral-sh/setup-uv@v6step to python-lint, python-typecheck, and python-test jobspip installcommands withuv pip install --systemequivalentsDeleted
src/python/requirements.txt— was a manual copy ofpyproject.tomldependenciessrc/python/requirements-test.txt— was a manual copy ofpyproject.tomltest groupAdded
src/python/uv.lock— deterministic lock file generated frompyproject.tomlTest plan
Closes #286
🤖 Generated with Claude Code
Summary by CodeRabbit