fix(review): stop the Code review row contradicting itself when AI never ran#7946
Merged
Conversation
…ver ran buildDualReviewNotes (FIX D1) deliberately folds the gate's own deterministic hard blockers into the same blocker list AI findings use, so a non-AI gate failure still populates "Why this is blocked" even with zero AI reviewers. But codeReviewRow's evidence text stayed "No AI review summary" unconditionally, so a PR blocked purely by a deterministic check (AI review inconclusive, e.g. a concurrent duplicate pass) rendered "1 blocker (No AI review summary)" -- reading as an AI pass that silently found something, not "AI review never ran; a separate check is what's blocking this." A blocker present with reviewerCount 0 can only be that deterministic fold-in (a fresh ai_consensus_defect needs an actual review pass to exist), so the evidence text now says so plainly in that case.
Contributor
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #7946 +/- ##
==========================================
- Coverage 91.83% 89.12% -2.71%
==========================================
Files 735 91 -644
Lines 75433 21762 -53671
Branches 22950 3819 -19131
==========================================
- Hits 69272 19396 -49876
+ Misses 5083 2187 -2896
+ Partials 1078 179 -899
Flags with carried forward coverage won't be shown. Click here to find out more.
|
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.
Summary
buildDualReviewNotes's FIX D1 deliberately folds gate blockers into the same list), the unified comment rendered a self-contradictory "1 blocker (No AI review summary)" line — reading as an AI pass that silently found something, when actually AI review never ran and something else entirely is blocking the PR.codeReviewRownow says so plainly: "1 blocker (no AI review ran — blocker is from a non-AI gate check)" whenreviewerCountis 0 and a blocker is present. The zero-blocker case ("No blockers (No AI review summary)") is unchanged.Scope
Validation
npm run typechecknpx vitest run test/unit/unified-comment.test.ts— 105 passed (2 new)Notes