Use path mapping collision support in HeaderDiscovery#29611
Draft
layus wants to merge 1 commit into
Draft
Conversation
2 tasks
|
@layus Could you please take a look at the failing checks? |
Contributor
Author
|
Also, there is something fishy about these ubuntu tests. They failed on all my recent PRs. |
Collaborator
|
Rebasong onto latest master should fix the failures |
b1fc41d to
5093972
Compare
Update HeaderDiscovery to use Multimap for tracking artifacts, enabling it to handle path-mapped collisions where artifacts from different configurations map to the same path in order to track the dependency on all the conflicting sources instead of the first.
5093972 to
8ab0634
Compare
Contributor
Author
|
Okay, I had my git repo in a broken state where upstream would not update correctly. Fixed for all four PRs. |
fmeum
reviewed
May 21, 2026
| inputs.add(treeArtifact); | ||
| Collection<SpecialArtifact> owningTreeArtifacts = | ||
| findOwningTreeArtifacts(execPathFragment, treeArtifacts, pathMapper); | ||
| if (!owningTreeArtifacts.isEmpty()) { |
Collaborator
There was a problem hiding this comment.
This logic seems wrong, I think we would need to verify that all artifacts have an owning tree artifact, not just one.
Contributor
Author
There was a problem hiding this comment.
You are completely right, the whole findOwningTreeArtifacts is bad.
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.
Description
This adds a multimap to track all the artefacts behind a sandbox path in header discovery.
Motivation
This should enable header discovery to properly track dependencies on multiple inputs providing the same in put path.
This is in particular important for path mapping, where files can be mapped to the same path with #29601.
Build API Changes
No
Checklist
Release Notes
RELNOTES: None