Add constraint dependencies to pyproject.toml (#5248)

Resolves #4467.

## Summary

This PR implements the following

1. Add `tool.uv.constraint-dependencies` to pyproject.toml
1. Support to refer `tool.uv.constraint-dependencies` in `uv lock`
1. Support to refer `tool.uv.constraint-dependencies` in `uv pip
compile/install`

These are analogues of the override features implemented in #3839 and
#4369.

## Test Plan

Add test.
This commit is contained in:
Di-Is 2024-07-22 08:45:04 +09:00 committed by GitHub
parent a917cdba51
commit 32ad3323a1
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
13 changed files with 243 additions and 1 deletions

View file

@ -104,6 +104,7 @@ pub struct ToolUv {
)
)]
pub override_dependencies: Option<Vec<pep508_rs::Requirement<VerbatimParsedUrl>>>,
pub constraint_dependencies: Option<Vec<pep508_rs::Requirement<VerbatimParsedUrl>>>,
}
#[derive(Serialize, Deserialize, OptionsMetadata, Default, Debug, Clone, PartialEq, Eq)]