uv/crates/uv-requirements/src
Charlie Marsh dff9ced40a Support conflicting editable settings across groups (#14197)
If a user specifies `-e /path/to/dir` and `/path/to/dir` in a `uv pip
install` command, we want the editable to "win" (rather than erroring
due to conflicting URLs). Unfortunately, this behavior meant that when
you requested a package as editable and non-editable in conflicting
groups, the editable version was _always_ used. This PR modifies the
requisite types to use `Option<bool>` rather than `bool` for the
`editable` field, so we can determine whether a requirement was
explicitly requested as editable, explicitly requested as non-editable,
or not specified (as in the case of `/path/to/dir` in a
`requirements.txt` file). In the latter case, we allow editables to
override the "unspecified" requirement.

If a project includes a path dependency twice, once with `editable =
true` and once without any `editable` annotation, those are now
considered conflicting URLs, and lead to an error, so I've marked this
change as breaking.

Closes https://github.com/astral-sh/uv/issues/14139.
2025-07-17 17:20:21 -05:00
..
extras.rs Bump MSRV to 1.85 and Edition 2024 (#13516) 2025-05-18 19:38:43 -04:00
lib.rs Add `UV_HTTP_RETRIES` to customize retry counts (#14544) 2025-07-11 07:35:27 -05:00
lookahead.rs Bump MSRV to 1.85 and Edition 2024 (#13516) 2025-05-18 19:38:43 -04:00
source_tree.rs Support conflicting editable settings across groups (#14197) 2025-07-17 17:20:21 -05:00
sources.rs Bump MSRV to 1.85 and Edition 2024 (#13516) 2025-05-18 19:38:43 -04:00
specification.rs Support reading dependency-groups from pyproject.tomls with no project (#13742) 2025-06-13 22:16:48 +00:00
unnamed.rs Bump MSRV to 1.85 and Edition 2024 (#13516) 2025-05-18 19:38:43 -04:00
upgrade.rs Show tag hints when failing to find a compatible wheel in `pylock.toml` (#13136) 2025-04-27 12:56:50 -04:00