Skip to content

Installing uv and python on Mac OS

Aaron Elkiss edited this page Oct 5, 2026 · 1 revision

Recommendation: use brew to install uv, and let uv itself manage the Python version — you do not need pyenv or a separate Python install. This repo currently requires Python 3.14+ (requires-python in the root pyproject.toml).

  • Install uv:
    • brew install uv (see the official installation docs for alternatives, e.g. the standalone installer curl -LsSf https://astral.sh/uv/install.sh | sh).
    • Verify: uv --version.
  • Install/select the Python version with uv (no separate brew install python or pyenv needed):
    • uv python install 3.14 — downloads and manages a Python 3.14 build for you.
    • uv python list — see the Python versions uv knows about, including any already on your machine.
    • uv automatically picks up the version pinned by requires-python in pyproject.toml when you run uv sync/uv run in the repo, so you rarely need to select a version manually.
  • Set up the monorepo environment:
    • From the repo root: uv sync — installs dependencies for the workspace and creates the shared virtual environment (.venv) per the single root uv.lock.
    • Activate it directly if you want a plain shell: source .venv/bin/activate, or just prefix commands with uv run (e.g. uv run pytest, uv run python --version) which does not require activation.
  • Useful uv commands (see the CLI reference for the full list):
    • uv sync — install/update dependencies and create the virtualenv.
    • uv run <command> — run a command inside the project's virtualenv without activating it.
    • uv add <package> / uv remove <package> — add/remove a dependency in the current project's pyproject.toml.
    • uv lock --upgrade — regenerate the lockfile with the latest compatible versions.
    • uv tree — inspect the dependency tree.
  • Python Linter:
  • Ruff: https://astral.sh/ruff
  • Enhancing Python Code Quality: A Comprehensive Guide to Linting with
  • Ruff: https://dev.to/ken_mwaura1/enhancing-python-code-quality-a-comprehensive-guide-to-linting-with-ruff-3d6g

Clone this wiki locally