Skip to main content

An extremely fast Python package and project manager, written in Rust.

Project description

uv

uv image image image Actions status Discord

An extremely fast Python package and project manager, written in Rust.

Shows a bar chart with benchmark results.

Installing Trio's dependencies with a warm cache.

Highlights

uv is backed by Astral, the creators of Ruff.

Installation

Install uv with our standalone installers:

# On macOS and Linux.
curl -LsSf https://astral.sh/uv/install.sh | sh
# On Windows.
powershell -ExecutionPolicy ByPass -c "irm https://astral.sh/uv/install.ps1 | iex"

Or, from PyPI:

# With pip.
pip install uv
# Or pipx.
pipx install uv

If installed via the standalone installer, uv can update itself to the latest version:

uv self update

See the installation documentation for details and alternative installation methods.

Documentation

uv's documentation is available at docs.astral.sh/uv.

Additionally, the command line reference documentation can be viewed with uv help.

Features

Projects

uv manages project dependencies and environments, with support for lockfiles, workspaces, and more, similar to rye or poetry:

$ uv init example
Initialized project `example` at `/home/user/example`

$ cd example

$ uv add ruff
Creating virtual environment at: .venv
Resolved 2 packages in 170ms
   Built example @ file:///home/user/example
Prepared 2 packages in 627ms
Installed 2 packages in 1ms
 + example==0.1.0 (from file:///home/user/example)
 + ruff==0.5.0

$ uv run ruff check
All checks passed!

$ uv lock
Resolved 2 packages in 0.33ms

$ uv sync
Resolved 2 packages in 0.70ms
Audited 1 package in 0.02ms

See the project documentation to get started.

uv also supports building and publishing projects, even if they're not managed with uv. See the publish guide to learn more.

Scripts

uv manages dependencies and environments for single-file scripts.

Create a new script and add inline metadata declaring its dependencies:

$ echo 'import requests; print(requests.get("https://astral.sh"))' > example.py

$ uv add --script example.py requests
Updated `example.py`

Then, run the script in an isolated virtual environment:

$ uv run example.py
Reading inline script metadata from: example.py
Installed 5 packages in 12ms
<Response [200]>

See the scripts documentation to get started.

Tools

uv executes and installs command-line tools provided by Python packages, similar to pipx.

Run a tool in an ephemeral environment using uvx (an alias for uv tool run):

$ uvx pycowsay 'hello world!'
Resolved 1 package in 167ms
Installed 1 package in 9ms
 + pycowsay==0.0.0.2
  """

  ------------
< hello world! >
  ------------
   \   ^__^
    \  (oo)\_______
       (__)\       )\/\
           ||----w |
           ||     ||

Install a tool with uv tool install:

$ uv tool install ruff
Resolved 1 package in 6ms
Installed 1 package in 2ms
 + ruff==0.5.0
Installed 1 executable: ruff

$ ruff --version
ruff 0.5.0

See the tools documentation to get started.

Python versions

uv installs Python and allows quickly switching between versions.

Install multiple Python versions:

$ uv python install 3.10 3.11 3.12
Searching for Python versions matching: Python 3.10
Searching for Python versions matching: Python 3.11
Searching for Python versions matching: Python 3.12
Installed 3 versions in 3.42s
 + cpython-3.10.14-macos-aarch64-none
 + cpython-3.11.9-macos-aarch64-none
 + cpython-3.12.4-macos-aarch64-none

Download Python versions as needed:

$ uv venv --python 3.12.0
Using Python 3.12.0
Creating virtual environment at: .venv
Activate with: source .venv/bin/activate

$ uv run --python [email protected] -- python --version
Python 3.8.16 (a9dbdca6fc3286b0addd2240f11d97d8e8de187a, Dec 29 2022, 11:45:30)
[PyPy 7.3.11 with GCC Apple LLVM 13.1.6 (clang-1316.0.21.2.5)] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>>>

Use a specific Python version in the current directory:

$ uv python pin 3.11
Pinned `.python-version` to `3.11`

See the Python installation documentation to get started.

The pip interface

uv provides a drop-in replacement for common pip, pip-tools, and virtualenv commands.

uv extends their interfaces with advanced features, such as dependency version overrides, platform-independent resolutions, reproducible resolutions, alternative resolution strategies, and more.

Migrate to uv without changing your existing workflows — and experience a 10-100x speedup — with the uv pip interface.

Compile requirements into a platform-independent requirements file:

$ uv pip compile docs/requirements.in \
   --universal \
   --output-file docs/requirements.txt
Resolved 43 packages in 12ms

Create a virtual environment:

$ uv venv
Using Python 3.12.3
Creating virtual environment at: .venv
Activate with: source .venv/bin/activate

Install the locked requirements:

$ uv pip sync docs/requirements.txt
Resolved 43 packages in 11ms
Installed 43 packages in 208ms
 + babel==2.15.0
 + black==24.4.2
 + certifi==2024.7.4
 ...

See the pip interface documentation to get started.

Platform support

See uv's platform support document.

Versioning policy

See uv's versioning policy document.

Contributing

We are passionate about supporting contributors of all levels of experience and would love to see you get involved in the project. See the contributing guide to get started.

Acknowledgements

uv's dependency resolver uses PubGrub under the hood. We're grateful to the PubGrub maintainers, especially Jacob Finkelman, for their support.

uv's Git implementation is based on Cargo.

Some of uv's optimizations are inspired by the great work we've seen in pnpm, Orogene, and Bun. We've also learned a lot from Nathaniel J. Smith's Posy and adapted its trampoline for Windows support.

License

uv is licensed under either of

at your option.

Unless you explicitly state otherwise, any contribution intentionally submitted for inclusion in uv by you, as defined in the Apache-2.0 license, shall be dually licensed as above, without any additional terms or conditions.

Project details


Release history Release notifications | RSS feed

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

uv-0.6.17.tar.gz (3.3 MB view details)

Uploaded Source

Built Distributions

uv-0.6.17-py3-none-win_arm64.whl (16.7 MB view details)

Uploaded Python 3 Windows ARM64

uv-0.6.17-py3-none-win_amd64.whl (18.0 MB view details)

Uploaded Python 3 Windows x86-64

uv-0.6.17-py3-none-win32.whl (16.5 MB view details)

Uploaded Python 3 Windows x86

uv-0.6.17-py3-none-musllinux_1_1_x86_64.whl (17.3 MB view details)

Uploaded Python 3 musllinux: musl 1.1+ x86-64

uv-0.6.17-py3-none-musllinux_1_1_i686.whl (16.5 MB view details)

Uploaded Python 3 musllinux: musl 1.1+ i686

uv-0.6.17-py3-none-musllinux_1_1_armv7l.whl (16.2 MB view details)

Uploaded Python 3 musllinux: musl 1.1+ ARMv7l

uv-0.6.17-py3-none-manylinux_2_28_aarch64.whl (16.0 MB view details)

Uploaded Python 3 manylinux: glibc 2.28+ ARM64

uv-0.6.17-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (17.2 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ x86-64

uv-0.6.17-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl (21.9 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ s390x

uv-0.6.17-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl (17.5 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ppc64le

uv-0.6.17-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl (17.8 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ppc64

uv-0.6.17-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl (16.9 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ i686

uv-0.6.17-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl (16.2 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARMv7l

uv-0.6.17-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.musllinux_1_1_aarch64.whl (15.7 MB view details)

Uploaded Python 3 manylinux: glibc 2.17+ ARM64 musllinux: musl 1.1+ ARM64

uv-0.6.17-py3-none-macosx_11_0_arm64.whl (15.3 MB view details)

Uploaded Python 3 macOS 11.0+ ARM64

uv-0.6.17-py3-none-macosx_10_12_x86_64.whl (16.6 MB view details)

Uploaded Python 3 macOS 10.12+ x86-64

uv-0.6.17-py3-none-linux_armv6l.whl (16.5 MB view details)

Uploaded Python 3

File details

Details for the file uv-0.6.17.tar.gz.

File metadata

  • Download URL: uv-0.6.17.tar.gz
  • Upload date:
  • Size: 3.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.6.16

File hashes

Hashes for uv-0.6.17.tar.gz
Algorithm Hash digest
SHA256 cbd40a6f8bdf7a96145af01dcf54252c0c9ddf749f21bfa5b7510fe7bc6d7880
MD5 7ca10e0028c0a017edd226673e9e9e5b
BLAKE2b-256 9cc37bf2ebea42e54f6f82dd7ac0321d20d05ccba144c24844423905ffe351cb

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-win_arm64.whl.

File metadata

  • Download URL: uv-0.6.17-py3-none-win_arm64.whl
  • Upload date:
  • Size: 16.7 MB
  • Tags: Python 3, Windows ARM64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.6.16

File hashes

Hashes for uv-0.6.17-py3-none-win_arm64.whl
Algorithm Hash digest
SHA256 a1117c3787f370b751e01625ee373d53058a5794bb627722d24e98e1c674da21
MD5 f72ea9abf36ea6e0244bf2c35783c77d
BLAKE2b-256 6082103134de796511b1dd33412cc5e6c650ca504116db8890b36f16ac938d06

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-win_amd64.whl.

File metadata

  • Download URL: uv-0.6.17-py3-none-win_amd64.whl
  • Upload date:
  • Size: 18.0 MB
  • Tags: Python 3, Windows x86-64
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.6.16

File hashes

Hashes for uv-0.6.17-py3-none-win_amd64.whl
Algorithm Hash digest
SHA256 b815d20ffd1ad6cd872227d1f92a29311ba27c519bb8c541e75125496d129e7d
MD5 daf38adbb7ec58f019893ed1d1e7091a
BLAKE2b-256 cdcab780d79df46a775cf7f725084dde2d1c7b299d176467822dce92361f4455

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-win32.whl.

File metadata

  • Download URL: uv-0.6.17-py3-none-win32.whl
  • Upload date:
  • Size: 16.5 MB
  • Tags: Python 3, Windows x86
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.6.16

File hashes

Hashes for uv-0.6.17-py3-none-win32.whl
Algorithm Hash digest
SHA256 d4b95d908a86fdab0302ed15435f2bf600527ba6ffc0611dee4c4892ae0cf948
MD5 1ec74f380c4afd0f9e8d3278b86716ca
BLAKE2b-256 4eb5542483462ec2ff5b7999df9a0541c83fe7302c126caa91d7f067438aa59d

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-musllinux_1_1_x86_64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-musllinux_1_1_x86_64.whl
Algorithm Hash digest
SHA256 da43740d0529ba4bbd365c06376bd01ecb703bb377537782203254af894621e6
MD5 cdb7b6b66b3ea68db7541d642d848d3f
BLAKE2b-256 fb90c130b326979ac94ca9af2c5bf9241c64aacccc3c6ccb326fbdeba2e7c194

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-musllinux_1_1_i686.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-musllinux_1_1_i686.whl
Algorithm Hash digest
SHA256 a3aaf2e8f2c2e998328ea59c1a1d5f7477c7ad70c66fefe61dc59a854f37f9aa
MD5 cdb6af90233abde69c543d6bf8ebe135
BLAKE2b-256 18646c265eafb4b63302f80d34dbca223c6c6952d1d3a7bc9e506a76273cb09f

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-musllinux_1_1_armv7l.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-musllinux_1_1_armv7l.whl
Algorithm Hash digest
SHA256 cedc26bc108916c50b1f9c4bb0c538a865fe2d2bee1053f2e13664445482d8c0
MD5 9608a2c93cc155a62680d37c14dc4d14
BLAKE2b-256 69322ad226d4bfea58882919fb17461221b83853fc5d7091120401a18139364c

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_28_aarch64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_28_aarch64.whl
Algorithm Hash digest
SHA256 d68686d0f602ea01b388fc9461b980e5095802eacf914a8b67c4b52c8f511eaf
MD5 1daff9972b90e5d71da1215ac1bf8a88
BLAKE2b-256 0c72b7cce8915bd639799e689d139b8ae8a39a12a70572fef96c5393159e31ec

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 aa416f287c81bfffd21e82765944035e6c3f4566615bd4fc03db3a704be8e4d5
MD5 746cff8341ccfb71ef27ae33b1cca384
BLAKE2b-256 d46b1bea7cff3104890b33c73155c811e48129eed8272e6f4ba848a116994fa4

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_s390x.manylinux2014_s390x.whl
Algorithm Hash digest
SHA256 71851ecf608504878c0dbe0f4523d3b82398c0947eefa06a53f09100d6e4eadb
MD5 f2cb763633a1f6370140aa03ede387d8
BLAKE2b-256 75701f1b4c17f3e6058cfb6ee625ec09eae05d4dab998c45ddc1b986f08d9648

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_ppc64le.manylinux2014_ppc64le.whl
Algorithm Hash digest
SHA256 d234bdf77ad466cf8a1dd432431b55e4ea070fc737fffa6ff7315c7678e50387
MD5 c506a570f51f66eb4817c8fbbc568e57
BLAKE2b-256 119c4f2c441366adaaa59ee1c1d6f3416bcdc1666e065e0faf56203cc7d19583

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_ppc64.manylinux2014_ppc64.whl
Algorithm Hash digest
SHA256 ce6c58d08431c28bcbc059912690bffea761083e2dd66b1d5cc2b95c5f5cf1fd
MD5 1ea37be20955a29a5eaf94981e85fdcf
BLAKE2b-256 32b1743958cf427becbfb05dce26721a63e7073d21acf805173f73ed089e5e38

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_i686.manylinux2014_i686.whl
Algorithm Hash digest
SHA256 b05f991079b9d6231a4d2fcb025989ac998aeb5379d57c90b2b93063733a7d37
MD5 7a7fd85256c5cf34e5d335423f8a0799
BLAKE2b-256 f3b0a1b5fd8fcf895b395d03aafbadc629ff856e435e16014af7f0e4c71b53e6

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_armv7l.manylinux2014_armv7l.whl
Algorithm Hash digest
SHA256 8f734c4e3936920bf2b12a581c67de599b2ec503da5fb270eaee0bb9d6d24368
MD5 9ce863fdc9d3f7e9b9a4b4892ae58367
BLAKE2b-256 5609df1e31d019a597e9e96bce51f503b13f4704671ea7dfced8e2e84211154b

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.musllinux_1_1_aarch64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-manylinux_2_17_aarch64.manylinux2014_aarch64.musllinux_1_1_aarch64.whl
Algorithm Hash digest
SHA256 fc95d87cbc20cbafb45f2a86b4e1bceddb048a825cc6fd2ca4bf7c3c34fc70c9
MD5 41d0a771834c0c0edc50b9646aa376b5
BLAKE2b-256 6e5bea18e6dbca255eddbc5c8886fe3a6ee2902cff5fdba6aadf2acc7db700d2

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 ce243bec19c47cc274e7e9eedbaeeb3dacbe94430b0f085dd506ba15a41676ee
MD5 a646fe44c438f12f6708f331faa44214
BLAKE2b-256 a54f66c7153120c155446f319647c1bafec2d9288f2b48d769cd9f9da39aa1f2

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 094026a024818b0c1d2c5794c9b5c20f6b97c74335e7ae088ac121afbae1fd7e
MD5 dd065ccb561458a6eb1579ba2f152ccd
BLAKE2b-256 eda287a989c57f92d60bc3d5751ac1dc2ce16cef2a73e2abfa9c4e50d4cdb7f7

See more details on using hashes here.

File details

Details for the file uv-0.6.17-py3-none-linux_armv6l.whl.

File metadata

File hashes

Hashes for uv-0.6.17-py3-none-linux_armv6l.whl
Algorithm Hash digest
SHA256 8e8d084e2f90e2e0648d4b3c3d5fc92669b2764b5c34f276de6d572cf5e498bf
MD5 8203adca5cb6d922520bdb903ce236e6
BLAKE2b-256 368270c83916ac40feaeb1920177e71d27b4ed90c7cd634e358276c246c58d29

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page