Skip to content

uv executable not found when installed with pipx install nox[uv] #791

@edgarrmondragon

Description

@edgarrmondragon

Current Behavior

The following exception is raised when a global uv installation is not available.

ValueError: No backends present, looked for ['uv'].

msg = f"No backends present, looked for {backends!r}."

The underlying cause seems to be shutil.which("uv") not being able to find uv installed alongside nox.

"uv": shutil.which("uv") is not None,

Expected Behavior

Installing nox[uv] is sufficient to use uv as a backend, without relying on a global uv installation.

Steps To Reproduce

  1. Install nox[uv]
  2. Configure uv as a venv backend, for example by setting nox.options.default_venv_backend = "uv" in the Noxfile
  3. Run any session

Environment

- OS: macOS
- Python: 3.12
- Nox: 2024.3.2

Anything else?

No response

Metadata

Metadata

Assignees

No one assigned

    Labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions