mirror of https://github.com/astral-sh/uv
Link to Dependency specifiers instead of PEP 508 (#8411)
The canonical source is https://packaging.python.org/en/latest/specifications/dependency-specifiers/, not PEP 508 anymore, so we should link there and use the new name.
This commit is contained in:
parent
40f842df09
commit
0dd4d017e3
|
|
@ -33,7 +33,9 @@ Utilities for interacting with Python version numbers and specifiers.
|
||||||
|
|
||||||
## [uv-pep508-rs](./uv-pep508)
|
## [uv-pep508-rs](./uv-pep508)
|
||||||
|
|
||||||
Utilities for interacting with [PEP 508](https://peps.python.org/pep-0508/) dependency specifiers.
|
Utilities for parsing and evaluating
|
||||||
|
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/),
|
||||||
|
previously known as [PEP 508](https://peps.python.org/pep-0508/).
|
||||||
|
|
||||||
## [uv-platform-tags](./uv-platform-tags)
|
## [uv-platform-tags](./uv-platform-tags)
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -3,9 +3,9 @@
|
||||||
[](https://crates.io/crates/pep508_rs)
|
[](https://crates.io/crates/pep508_rs)
|
||||||
[](https://pypi.org/project/pep508_rs)
|
[](https://pypi.org/project/pep508_rs)
|
||||||
|
|
||||||
A library for python
|
A library for
|
||||||
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/),
|
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/),
|
||||||
better known as [PEP 508](https://peps.python.org/pep-0508/).
|
previously known as [PEP 508](https://peps.python.org/pep-0508/).
|
||||||
|
|
||||||
## Usage
|
## Usage
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -1,5 +1,5 @@
|
||||||
//! A library for python [dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/)
|
//! A library for [dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/)
|
||||||
//! better known as [PEP 508](https://peps.python.org/pep-0508/)
|
//! previously known as [PEP 508](https://peps.python.org/pep-0508/)
|
||||||
//!
|
//!
|
||||||
//! ## Usage
|
//! ## Usage
|
||||||
//!
|
//!
|
||||||
|
|
|
||||||
|
|
@ -28,9 +28,10 @@ bird-feeder = { path = "./packages/bird-feeder" }
|
||||||
## Project dependencies
|
## Project dependencies
|
||||||
|
|
||||||
The `project.dependencies` table represents the dependencies that are used when uploading to PyPI or
|
The `project.dependencies` table represents the dependencies that are used when uploading to PyPI or
|
||||||
building a wheel. Individual dependencies are specified using [PEP 508](#pep-508) syntax, and the
|
building a wheel. Individual dependencies are specified using
|
||||||
table follows the [PEP 621](https://packaging.python.org/en/latest/specifications/pyproject-toml/)
|
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/)
|
||||||
standard.
|
syntax, and the table follows the
|
||||||
|
[PEP 621](https://packaging.python.org/en/latest/specifications/pyproject-toml/) standard.
|
||||||
|
|
||||||
`project.dependencies` defines the list of packages that are required for the project, along with
|
`project.dependencies` defines the list of packages that are required for the project, along with
|
||||||
the version constraints that should be used when installing them. Each entry includes a dependency
|
the version constraints that should be used when installing them. Each entry includes a dependency
|
||||||
|
|
@ -248,8 +249,8 @@ members = [
|
||||||
### Platform-specific sources
|
### Platform-specific sources
|
||||||
|
|
||||||
You can limit a source to a given platform or Python version by providing
|
You can limit a source to a given platform or Python version by providing
|
||||||
[PEP 508](https://peps.python.org/pep-0508/#environment-markers)-compatible environment markers for
|
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/)-compatible
|
||||||
the source.
|
environment markers for the source.
|
||||||
|
|
||||||
For example, to pull `httpx` from GitHub, but only on macOS, use the following:
|
For example, to pull `httpx` from GitHub, but only on macOS, use the following:
|
||||||
|
|
||||||
|
|
@ -320,7 +321,8 @@ installation of Excel parsers and `matplotlib` unless someone explicitly require
|
||||||
requested with the `package[<extra>]` syntax, e.g., `pandas[plot, excel]`.
|
requested with the `package[<extra>]` syntax, e.g., `pandas[plot, excel]`.
|
||||||
|
|
||||||
Optional dependencies are specified in `[project.optional-dependencies]`, a TOML table that maps
|
Optional dependencies are specified in `[project.optional-dependencies]`, a TOML table that maps
|
||||||
from extra name to its dependencies, following [PEP 508](#pep-508) syntax.
|
from extra name to its dependencies, following
|
||||||
|
[dependency specifiers](#dependency-specifiers-pep-508) syntax.
|
||||||
|
|
||||||
Optional dependencies can have entries in `tool.uv.sources` the same as normal dependencies.
|
Optional dependencies can have entries in `tool.uv.sources` the same as normal dependencies.
|
||||||
|
|
||||||
|
|
@ -437,10 +439,12 @@ Or, to opt-out of using an editable dependency in a workspace:
|
||||||
$ uv add --no-editable ./path/foo
|
$ uv add --no-editable ./path/foo
|
||||||
```
|
```
|
||||||
|
|
||||||
## PEP 508
|
## Dependency specifiers (PEP 508)
|
||||||
|
|
||||||
[PEP 508](https://peps.python.org/pep-0508/) defines a syntax for dependency specification. It is
|
uv uses
|
||||||
composed of, in order:
|
[dependency specifiers](https://packaging.python.org/en/latest/specifications/dependency-specifiers/),
|
||||||
|
previously known as [PEP 508](https://peps.python.org/pep-0508/). A dependency specifier is composed
|
||||||
|
of, in order:
|
||||||
|
|
||||||
- The dependency name
|
- The dependency name
|
||||||
- The extras you want (optional)
|
- The extras you want (optional)
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue