fix(review): keep gate evaluation for ignored authors - #3698
Conversation
|
Superagent didn't find any vulnerabilities or security issues in this PR. |
|
Caution 🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥🟥 🛑 Gittensory review result - fixes requiredReview updated: 2026-07-06 08:27:59 UTC
🛑 Suggested Action - Manual Review
Review summary Nits — 5 non-blocking
Why this is blocked
CI checks failing
Review context
Contributor next steps
Signal definitions
🟩 Safe / merged · 🟦 Advisory · 🟨 Held for review · 🟥 Blocked / closed 💰 Earn for open-source contributions like this. Gittensor lets GitHub contributors earn for the work they already do — register to start earning →. Checked by Gittensory, a quiet PR intelligence layer for OSS maintainers.
|
Codecov Report✅ All modified and coverable lines are covered by tests. Additional details and impacted files@@ Coverage Diff @@
## main #3698 +/- ##
==========================================
- Coverage 93.29% 93.29% -0.01%
==========================================
Files 317 317
Lines 32368 32367 -1
Branches 11872 11872
==========================================
- Hits 30199 30198 -1
Misses 1537 1537
Partials 632 632
🚀 New features to boost your workflow:
|
e382cd8 to
066958c
Compare
066958c to
5b1d74c
Compare
#3694 (merged independently, unaware of this fix) made the gate check-run publish a quiet "skipped (reason)" status instead of the evaluated gate conclusion whenever auto-review is skipped -- including for an ignored author, since evaluateAutoReviewSkipReason checks the same review.auto_review.ignore_authors config this PR's own eligibility check does. That silently reintroduced the exact bypass this PR exists to close: an ignored author's PR would show "skipped" on its gate check-run instead of a real hard-rule failure (e.g. no linked issue), even though the gate evaluation itself was computed correctly. Only take the "skipped status" shortcut when publicSurfaceSkipped is false. publicSurfaceSkipped is already the flag this PR's ignored-author path (and decidePublicSurface's own skip conditions) sets specifically so the deterministic gate keeps reporting truthfully even when public review output is suppressed -- reusing it here keeps the two mechanisms consistent instead of introducing new reason-string matching. A benign content-based skip (draft, WIP title, too-large, docs-only, base-branch, auto-pause) never sets publicSurfaceSkipped, so #3694's quiet status is unaffected for those cases.
5b1d74c to
eb3810b
Compare
|
Rebased onto current `main`. Found and fixed an additional issue surfaced by the rebase: #3694 (merged independently, unaware of this PR) made the gate check-run publish a quiet "skipped (reason)" status whenever auto-review is skipped — including for an ignored author, since it checks the same `review.auto_review.ignore_authors` config this PR's eligibility check does. That silently reintroduced the exact bypass this PR closes: an ignored author's gate check-run would show "skipped" instead of the real evaluated conclusion (e.g. a linked-issue hard-rule failure). Fix: the "skipped status" shortcut now only applies when `publicSurfaceSkipped` is false — reusing the existing flag this PR's own ignored-author path already sets, rather than introducing new reason-string matching. A benign content-based skip (draft, WIP title, too-large, docs-only, base-branch, auto-pause) never sets `publicSurfaceSkipped`, so #3694's quiet status is unaffected for those cases. Full `test/unit/queue.test.ts` (588 tests) + typecheck + actionlint + audit all green locally. |
Motivation
review.auto_review.ignore_authorspath previously created a completedskippedgate check and returned early, which could suppress deterministic gate evaluation and allow requiredgateblockers (like linked-issue) to be bypassed.Description
maybePublishPrPublicSurface(src/queue/processors.ts) stop publishing a skipped gate check for ignored authors and avoid the earlyreturn; instead setpublicSurfaceSkipped = trueand only early-return whenshouldEvaluateGateis false. This preserves downstream deterministic gate computation such asevaluateGateCheck.!publicSurfaceSkippedguard to the type-label branch inmaybePublishPrPublicSurface(src/queue/processors.ts).test/unit/queue.test.ts) to assert that an ignored author still triggers the gate evaluation (POST+PATCH check-run sequence with afailureconclusion for a linked-issue block) and to adjust mocked call counts accordingly.Testing
git diff --checkwhich produced no whitespace/conflict errors and passed.npx vitest run test/unit/queue.test.ts -t "ignored authors" --reporter=verbose --no-colorwhich passed.npx vitest run test/unit/queue.test.ts -t "evaluates the gate while suppressing public review output for ignored authors|audits ignored authors without a skipped check" --reporter=verbose --no-colorwhich passed.npm run typecheck(tsc --noEmit) which completed without type errors.Codex Task