Theztefan/uv detector improvements#1844
Open
ryanbrandenburg wants to merge 15 commits into
Open
Conversation
…etector.cs Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
… into theztefan/uv-detector-improvements
Contributor
There was a problem hiding this comment.
Pull request overview
This PR updates the uv.lock detector to better reflect uv’s lockfile semantics by expanding dev-dependency handling and adding support for git-sourced packages, improving the accuracy of the produced dependency graph.
Changes:
- Parse all
[package.metadata.requires-dev]groups (not justdev) and classify dev-only packages via transitive reachability. - Register git-sourced uv packages as
GitComponent(repository URL + commit hash). - Add/extend tests and documentation for the new behaviors.
Show a summary per file
| File | Description |
|---|---|
| test/Microsoft.ComponentDetection.Detectors.Tests/UvLockDetectorTests.cs | Adds coverage for multiple dev groups, transitive dev propagation, and git source handling. |
| src/Microsoft.ComponentDetection.Detectors/uv/UvSource.cs | Extends the uv source model to include git. |
| src/Microsoft.ComponentDetection.Detectors/uv/UvLockComponentDetector.cs | Implements transitive dev-only classification and GitComponent registration. |
| src/Microsoft.ComponentDetection.Detectors/uv/UvLock.cs | Parses source.git and aggregates dev deps across all requires-dev groups. |
| docs/detectors/uv.md | Documents dev reachability classification and git-sourced component behavior. |
Review details
- Files reviewed: 5/5 changed files
- Comments generated: 3
- Review effort level: Low
… into theztefan/uv-detector-improvements
|
|
||
| internal static HashSet<string> GetTransitivePackages(IEnumerable<string> roots, List<UvPackage> packages) | ||
| { | ||
| var lookup = packages.ToDictionary(p => p.Name, p => p, StringComparer.OrdinalIgnoreCase); |
… into theztefan/uv-detector-improvements
|
👋 Hi! It looks like you modified some files in the
If none of the above scenarios apply, feel free to ignore this comment 🙂 |
grvillic
reviewed
Jul 14, 2026
grvillic
approved these changes
Jul 14, 2026
grvillic
reviewed
Jul 14, 2026
grvillic
approved these changes
Jul 15, 2026
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
This is the same PR as #1631, just updated for the changes since February. All credit goes to @theztefan.