Filter metadata files from rebase instruction conflict lists#5448
Merged
Filter metadata files from rebase instruction conflict lists#5448
Conversation
Member
|
@copilot try again |
Co-authored-by: premun <[email protected]>
premun
reviewed
Nov 7, 2025
premun
reviewed
Nov 7, 2025
Contributor
Author
Copilot
AI
changed the title
[WIP] Fix rebase instruction comments for conflicts
Filter metadata files from rebase instruction conflict lists
Nov 7, 2025
premun
reviewed
Nov 7, 2025
Co-authored-by: premun <[email protected]>
Co-authored-by: premun <[email protected]>
premun
approved these changes
Nov 10, 2025
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR adds filtering logic to pull request conflict comments for forward flow subscriptions, ensuring only relevant source files are included and metadata files are excluded.
- Filters conflicted file lists to show only files under the repository's source directory (e.g.,
src/sdk/) for forward flow - Implements case-insensitive path matching for cross-platform robustness
- Strips the
src/{targetDirectory}/prefix from displayed file paths for cleaner output
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| src/ProductConstructionService/ProductConstructionService.DependencyFlow/PullRequestCommentBuilder.cs | Adds filtering logic in AppendConflictedFileList to exclude metadata files and only show files under the target directory for forward flow subscriptions |
| test/ProductConstructionService.DependencyFlow.Tests/PullRequestCommentBuilderTests.cs | Adds three comprehensive tests verifying metadata file filtering, case-insensitive path matching, and proper path stripping for both conflict notification methods |
…ndencyFlow/PullRequestCommentBuilder.cs Co-authored-by: Copilot <[email protected]>
dkurepa
approved these changes
Nov 10, 2025
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.
Fixes an issue where rebase instruction comments were listing VMR metadata files like
source-manifest.jsonalongside actual source files in the conflict list.Changes Made
PullRequestCommentBuilder.AppendConflictedFileList: Added filtering logic to only include files under the repository source directory (src/{repo-name}/) for forward flow subscriptions with case-insensitive path matchingPullRequestCommentBuilderTests.csto verify the filtering works correctly for both conflict notification methods, including case-insensitive path matchingThe fix ensures that only actual source files from the repository are listed in conflict messages, excluding VMR-level metadata files like
src/source-manifest.jsonandsrc/git-info/*. Path matching is case-insensitive to handle variations in path casing.Example
For a forward flow subscription with
TargetDirectory = "sdk":src/sdk/file1.csorSRC/SDK/file1.csare included in the conflict list (case-insensitive)src/source-manifest.jsonare filtered outTesting
✅ Build succeeds with no errors or warnings
✅ All existing tests continue to pass
✅ New unit tests verify correct filtering behavior for forward flow subscriptions
✅ Case-insensitive path matching is validated with dedicated test
✅ Backward compatibility maintained for backflow subscriptions (no filtering applied)
Fixes Rebase instruction comment lists
source-manifest.jsonin conflicts #5447Original prompt
source-manifest.jsonin conflicts #5447✨ Let Copilot coding agent set things up for you — coding agent works faster and does higher quality work when set up for your repo.