uv/crates/pep508-rs/Cargo.toml
Charlie Marsh 23eb42deed
Allow constraints to be provided in --upgrade-package (#4952)
## Summary

Allows, e.g., `--upgrade-package flask<3.0.0`.

Closes https://github.com/astral-sh/uv/issues/1964.
2024-07-09 20:09:13 -07:00

58 lines
2.1 KiB
TOML

[package]
name = "pep508_rs"
version = "0.6.0"
description = "A library for python dependency specifiers, better known as PEP 508"
include = ["/src", "Changelog.md", "License-Apache", "License-BSD", "Readme.md", "pyproject.toml"]
license = "Apache-2.0 OR BSD-2-Clause"
edition = { workspace = true }
rust-version = { workspace = true }
homepage = { workspace = true }
documentation = { workspace = true }
repository = { workspace = true }
authors = { workspace = true }
[lib]
name = "pep508_rs"
crate-type = ["cdylib", "rlib"]
[lints]
workspace = true
[dependencies]
derivative = { workspace = true }
once_cell = { workspace = true }
pep440_rs = { workspace = true }
pyo3 = { workspace = true, optional = true, features = ["abi3", "extension-module"] }
pyo3-log = { workspace = true, optional = true }
regex = { workspace = true }
schemars = { workspace = true, optional = true }
serde = { workspace = true, features = ["derive", "rc"] }
serde_json = { workspace = true, optional = true }
thiserror = { workspace = true }
tracing = { workspace = true, optional = true }
unicode-width = { workspace = true }
url = { workspace = true, features = ["serde"] }
uv-fs = { workspace = true }
uv-normalize = { workspace = true }
[dev-dependencies]
insta = { version = "1.36.1" }
log = { version = "0.4.21" }
serde_json = { version = "1.0.114" }
testing_logger = { version = "0.1.1" }
[features]
pyo3 = ["dep:pyo3", "pep440_rs/pyo3", "pyo3-log", "tracing", "tracing/log"]
tracing = ["dep:tracing", "pep440_rs/tracing"]
schemars = ["dep:schemars"]
# PEP 508 allows only URLs such as `foo @ https://example.org/foo` or `foo @ file:///home/ferris/foo`, and
# arguably does not allow relative paths in file URLs (`foo @ file://./foo`,
# `foo @ file:foo-3.0.0-py3-none-any.whl`, `foo @ file://foo-3.0.0-py3-none-any.whl`), as they are not part of the
# relevant RFCs, even though widely supported. Pip accepts relative file URLs and paths instead of urls
# (`foo @ ./foo-3.0.0-py3-none-any.whl`). The `non-pep508-features` controls whether these non-spec features will
# be supported.
non-pep508-extensions = []
default = []
# Match the API of the published crate, for compatibility.
serde = []