Fix merge conflict detection in pr-review-needed workflow#13884
Merged
radical merged 3 commits intojamesnk/pr-tracking-action-wipfrom Jan 13, 2026
Merged
Fix merge conflict detection in pr-review-needed workflow#13884radical merged 3 commits intojamesnk/pr-tracking-action-wipfrom
radical merged 3 commits intojamesnk/pr-tracking-action-wipfrom
Conversation
Co-authored-by: radical <[email protected]>
Copilot
AI
changed the title
[WIP] Update PR review tracking workflow for better performance
Fix merge conflict detection in pr-review-needed workflow
Jan 13, 2026
Member
Co-authored-by: radical <[email protected]>
Contributor
Author
Enhanced the conflict detection logic in commit 34f00bd. The workflow now checks both |
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 subscribe to this conversation on GitHub.
Already have an account?
Sign in.
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
The workflow was incorrectly detecting merge conflicts because
mergeable_stateis not available in thepulls.listAPI response—it requires fetching individual PR details viapulls.get. Additionally, the initial implementation only checked formergeable_state === 'dirty', which missed edge cases where PRs have merge conflicts but GitHub doesn't explicitly set the state to 'dirty'.Changes:
mergeable_stateandmergeablefieldsmergeable_state === 'dirty'(definitive conflicts)mergeable === falseAND state is notblocked,behind,unstable,unknown, orclean(catches edge cases)mergeable_statevalues and their meaningsThis ensures all PRs with actual merge conflicts are correctly identified and marked with the ❌ emoji in the tracking issue, including edge cases that were previously missed.
Checklist
<remarks />and<code />elements on your triple slash comments?doc-ideatemplatebreaking-changetemplatediagnostictemplate💬 We'd love your input! Share your thoughts on Copilot coding agent in our 2 minute survey.