build(tmp-celery-flush): Migrate from pip to uv#55
Conversation
Replace requirements.txt with pyproject.toml and update run-celery.sh and start-task.sh to use uv for dependency management and execution. Refs PY-2482 Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 1 potential issue.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit af7a7b1. Configure here.
| redis-server --daemonize yes | ||
|
|
||
| celery -A tasks.app worker \ | ||
| uv run celery -A tasks.app worker \ |
There was a problem hiding this comment.
uv unavailable after inline install
Medium Severity
When uv is not already on PATH, the scripts run Astral’s installer and then immediately invoke uv run. The installer does not expose uv to the current shell session, so the next line fails with “command not found” under set -euo pipefail, breaking the PR test plan on a fresh environment.
Additional Locations (1)
Reviewed by Cursor Bugbot for commit af7a7b1. Configure here.
| if ! command -v uv &> /dev/null; then | ||
| curl -LsSf https://astral.sh/uv/install.sh | sh | ||
| fi |
There was a problem hiding this comment.
Bug: The script installs uv but fails to update the PATH for the current session, causing subsequent uv commands to fail with "command not found".
Severity: HIGH
Suggested Fix
After the uv installation block, add a line to update the PATH for the current shell session, for example: export PATH="$HOME/.local/bin:$PATH". This will ensure the uv binary is discoverable in subsequent commands within the same script execution.
Prompt for AI Agent
Review the code at the location below. A potential bug has been identified by an AI
agent. Verify if this is a real issue. If it is, propose a fix; if not, explain why it's
not valid.
Location: tmp-celery-flush/run-celery.sh#L4-L6
Potential issue: After installing `uv` via a curl script, the shell script immediately
attempts to use the `uv` command. The installer places the `uv` binary in `~/.local/bin`
and updates shell profile files, but these changes do not affect the current, running
shell session. Because the `PATH` is not updated for the current session, the `uv`
command is not found. As the script is configured with `set -euo pipefail`, this
"command not found" error will cause the script to exit immediately, preventing it from
completing its task. This failure occurs precisely in the scenario the installation
block is meant to handle—when `uv` is not already present.
Did we get this right? 👍 / 👎 to inform future reviews.


Summary
requirements.txtwithpyproject.tomlfor dependency managementrun-celery.shandstart-task.shto useuv runinstead of manual venv/pip workflowTest plan
./run-celery.shand verify the celery worker starts correctly./start-task.shand verify the task is dispatched🤖 Generated with Claude Code