uv/crates/uv-workspace
Frazer McLean 62692b4e1b
Fix detection of sorted dependencies when include-group is used (#13354)
This follows on from #13334 to fix another case.

<!--
Thank you for contributing to uv! To help us out with reviewing, please
consider the following:

- Does this pull request include a summary of the change? (See below.)
- Does this pull request include a descriptive title?
- Does this pull request include references to any relevant issues?
-->

## Summary

If a dependency group contained any `{ include-group = "..." }` entries,
the sort detection would bail out. The root cause of the problem was
gating the sort detection behind `deps.iter().all(Value::is_str)`.

A public code search reveals that keeping include-groups at the top is
by far the most common, but keeping them at the bottom isn't uncommon.
In both of these cases, uv will now preserve the convention that is in
use.

Unless I've missed it, I don't think uv supports `uv add`ing an
include-group, and so that wasn't tested here.

## Test Plan

cargo test

---------

Co-authored-by: Charlie Marsh <charlie.r.marsh@gmail.com>
2025-05-10 14:00:27 -04:00
..
src Fix detection of sorted dependencies when include-group is used (#13354) 2025-05-10 14:00:27 -04:00
Cargo.toml Build backend: Add reference docs and schema (#12803) 2025-04-21 12:27:49 +02:00