Context
src/rules/advisory.ts's buildCheckRunAnnotations already discloses truncation: when candidate annotations exceed CHECK_RUN_ANNOTATION_LIMIT, it computes omittedCount and formatCheckRunOutput appends "…N more hotspot annotation(s) omitted from inline check output." to the check-run text so a contributor knows more findings exist than are shown.
The sibling function that renders configured hard-blocker text, formatGateCheckOutput (same file, around line 744), truncates the same way but with no such disclosure:
const blockerLines = gate.blockers.slice(0, 8).map((finding) => {
const action = finding.action ? ` Action: ${sanitizeForCheckRun(finding.action)}` : "";
return `- ${sanitizeForCheckRun(finding.title)}.${action}`;
});
return {
title: gate.title.slice(0, 255),
summary: `${LOOPOVER_GATE_CHECK_NAME} found a repo-configured hard blocker.`,
text: blockerLines.length > 0 ? blockerLines.join("\n") : "A configured hard blocker was found.",
};
The 8 cap has no explanatory comment and no disclosure line. A contributor with 9+ genuine configured blockers sees only the first 8, fixes them, and only discovers the 9th (and beyond) on the next gate run — indistinguishable from the bot silently moving the goalposts. test/unit/rules.test.ts's existing coverage of formatGateCheckOutput tops out at 2 blockers (around line 623), so the gate.blockers.length > 8 path has no test today.
Requirements
- When
gate.blockers.length exceeds 8, formatGateCheckOutput's returned text must append a disclosure line naming how many additional blockers were omitted, following the same wording pattern already used by buildCheckRunAnnotations's omittedCount disclosure (e.g. "…N more configured blocker(s) omitted from inline check output.").
- The
8 truncation limit must be extracted to a named constant (e.g. GATE_CHECK_BLOCKER_LIMIT) with a one-line comment explaining its purpose, instead of remaining a bare magic number inline.
- The disclosure line must not appear when
gate.blockers.length <= 8 (i.e. no omission) — do not add the line unconditionally.
Deliverables
Test Coverage Requirements
This repo's Codecov patch gate requires 99%+ coverage of changed lines and branches. Both the truncated-with-disclosure branch and the not-truncated (no disclosure) branch must be independently covered.
Expected Outcome
A contributor with more than 8 configured hard blockers on a single PR sees an explicit "N more omitted" disclosure in the gate check's text, the same transparency buildCheckRunAnnotations already provides for annotations, instead of silently seeing only a partial list.
Links & Resources
src/rules/advisory.ts — formatGateCheckOutput (the gap, ~line 744) and buildCheckRunAnnotations's omittedCount pattern to mirror (~line 747-749 in formatCheckRunOutput)
test/unit/rules.test.ts — existing formatGateCheckOutput coverage, ~line 623
Context
src/rules/advisory.ts'sbuildCheckRunAnnotationsalready discloses truncation: when candidate annotations exceedCHECK_RUN_ANNOTATION_LIMIT, it computesomittedCountandformatCheckRunOutputappends"…N more hotspot annotation(s) omitted from inline check output."to the check-run text so a contributor knows more findings exist than are shown.The sibling function that renders configured hard-blocker text,
formatGateCheckOutput(same file, around line 744), truncates the same way but with no such disclosure:The
8cap has no explanatory comment and no disclosure line. A contributor with 9+ genuine configured blockers sees only the first 8, fixes them, and only discovers the 9th (and beyond) on the next gate run — indistinguishable from the bot silently moving the goalposts.test/unit/rules.test.ts's existing coverage offormatGateCheckOutputtops out at 2 blockers (around line 623), so thegate.blockers.length > 8path has no test today.Requirements
gate.blockers.lengthexceeds 8,formatGateCheckOutput's returnedtextmust append a disclosure line naming how many additional blockers were omitted, following the same wording pattern already used bybuildCheckRunAnnotations'somittedCountdisclosure (e.g."…N more configured blocker(s) omitted from inline check output.").8truncation limit must be extracted to a named constant (e.g.GATE_CHECK_BLOCKER_LIMIT) with a one-line comment explaining its purpose, instead of remaining a bare magic number inline.gate.blockers.length <= 8(i.e. no omission) — do not add the line unconditionally.Deliverables
GATE_CHECK_BLOCKER_LIMIT = 8) replacing the current inline8informatGateCheckOutput.textwhen blockers are truncated, mirroringbuildCheckRunAnnotations's omitted-count pattern.test/unit/rules.test.tswith more than 8 blockers asserting: (a) the disclosure text appears with the correct omitted count, and (b) a case with exactly 8 or fewer blockers asserting the disclosure text does NOT appear.Test Coverage Requirements
This repo's Codecov patch gate requires 99%+ coverage of changed lines and branches. Both the truncated-with-disclosure branch and the not-truncated (no disclosure) branch must be independently covered.
Expected Outcome
A contributor with more than 8 configured hard blockers on a single PR sees an explicit "N more omitted" disclosure in the gate check's text, the same transparency
buildCheckRunAnnotationsalready provides for annotations, instead of silently seeing only a partial list.Links & Resources
src/rules/advisory.ts—formatGateCheckOutput(the gap, ~line 744) andbuildCheckRunAnnotations'somittedCountpattern to mirror (~line 747-749 informatCheckRunOutput)test/unit/rules.test.ts— existingformatGateCheckOutputcoverage, ~line 623