Repository navigation
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 installercurl -LsSf https://astral.sh/uv/install.sh | sh). - Verify:
uv --version.
-
- Install/select the Python version with
uv(no separatebrew install pythonorpyenvneeded):-
uv python install 3.14— downloads and manages a Python 3.14 build for you. -
uv python list— see the Python versionsuvknows about, including any already on your machine. -
uvautomatically picks up the version pinned byrequires-pythoninpyproject.tomlwhen you runuv sync/uv runin 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 rootuv.lock. - Activate it directly if you want a plain shell:
source .venv/bin/activate, or just prefix commands withuv run(e.g.uv run pytest,uv run python --version) which does not require activation.
- From the repo root:
- Useful
uvcommands (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'spyproject.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