There was pip-tools
, but now there is uv
.
What is uv
uv
should replace pip
, pip-tools
, and even virtualenv
.
A drop-in compatible API
This initial release centers on what we refer to as uv’s
pip
API. It’ll be familiar to those that have used pip andpip-tools
in the past:Instead of pip install, run uv
pip install
to install Python dependencies from the command line, a requirements file, or apyproject.toml
.Instead of
pip-compile,
runuv pip compile
to generate a lockedrequirements.txt
.Instead of
pip-sync,
runuv pip sync
to sync a virtual environment with a lockedrequirements.txt
.
Advanced Resolution Strategies
uv
supports alternate resolution strategies. By default,uv
follows the standard Python dependency resolution strategy of preferring the latest compatible version of each package. But by passing--resolution=lowest
, library authors can test their packages against the lowest-compatible version of their dependencies.
uv
allows for resolutions against arbitrary target Python versions. Whilepip
andpip-tools
always resolve against the currently-installed Python version (generating, e.g., a Python 3.12-compatible resolution when running under Python 3.12),uv
accepts a--python-version
parameter, enabling you to generate, e.g., Python 3.7-compatible resolutions even when running under newer versions.
uv
allows for dependency “overrides”.uv
takes pip’s “constraints” concepts a step further via overrides (-o overrides.txt
), which allow the user to guide the resolver by overriding the declared dependencies of a package. Overrides give the user an escape hatch for working around erroneous upper bounds and other incorrectly-declared dependencies.