build: Install uv through brew - #6351
Conversation
There was a problem hiding this comment.
Cursor Bugbot has reviewed your changes and found 2 potential issues.
❌ Bugbot Autofix is OFF. To automatically fix reported issues with cloud agents, enable autofix in the Cursor dashboard.
Reviewed by Cursor Bugbot for commit bec4311. Configure here.
|
|
||
| # clean up leftover devenv uv install | ||
| binroot = fs.ensure_binroot(reporoot) | ||
| uv.uninstall(binroot) |
There was a problem hiding this comment.
Bug: The script unconditionally uninstalls uv but only provides a re-installation path for macOS, breaking the development environment setup for Linux users by leaving uv missing.
Severity: HIGH
Suggested Fix
Provide a cross-platform installation method for uv. This could involve adding a specific installation step for Linux, similar to the previous implementation that downloaded pre-compiled binaries, or using a package manager available on Linux.
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: devenv/sync.py#L12
Potential issue: The script unconditionally calls `uv.uninstall(binroot)` on line 12,
removing the `uv` executable from the development environment on all platforms. However,
the subsequent installation of `uv` is handled by `brew bundle`, which is only executed
on macOS due to an `if constants.DARWIN` check. On Linux systems, `uv` is removed but
never re-installed. This causes the script to fail later at a check for the `uv`
executable (`shutil.which("uv")`), resulting in a `SystemExit` with a misleading error
message suggesting the user run `direnv allow`, which will not resolve the issue.

I'm getting a warning on every
devenv syncsaying that installinguvthroughdevenvis no longer supported:So I'm removing that code and adding
uvto the brewfile instead.