Repository navigation
[quality] coverage-e2e names tide.ts:99 uncovered; the zero is the never-reached options.initial ?? await getPull fallback on line 98 #466
Description
Finding
npm run test:coverage:e2e (main @ 7f01721, local run) reports src/plugins/tide.ts as 99.56% Stmts / 93.98% Branch, with line 99 (for (const delay of unknownRetryDelaysMs)) listed as uncovered. That line is not uncovered: in the same coverage-e2e/lcov.info the loop body executes (DA:100,65).
What the zero really is: the ?? await getPull(...) fallback on line 98
let pr = options.initial ?? await getPull(octokit, context, number)Both fetchMergeability call sites (evaluateMerge, tide.ts:198-201, and evaluateInQueue, tide.ts:307-310) pass initial: first, so the right-hand side never runs from dist/index.js:
coverage-e2e/lcov.info SF:src/plugins/tide.ts
DA:98,60 BRDA:98,0,0,60 BRDA:98,0,1,0 DA:99,0 DA:100,65
V8/istanbul attributes that zero-count ?? range to the following line, which is why the report names 99. The unit run shows the same attribution (coverage/lcov.info: BRDA:98,0,1,7 and DA:99,7 while DA:100,135); it just is not visible there because the unit suite does call fetchMergeability without initial. Of the 52 for … of headers in src/, this is the only one the e2e report zeroes.
Only the unit tests exercise the fallback. It is the same shape as the arms #462 removed for #458 (retryIf default in this very function), and was not in that list.
Recommendation
Follow #462: make initial required in FetchMergeabilityOptions and drop the ?? await getPull(...) fallback (plus the unit cases that only reach it); rebuild dist/. After that, tide.ts no longer appears in the e2e "Uncovered Line #s" column for this reason, and the report stops pointing at a line that does run.
-
FetchMergeabilityOptions.initialrequired; line-98 fallback removed;dist/repacked -
npm run test:coverage:e2eno longer liststide.ts:99
This is a production-code change, so no PR accompanies this issue. The related e2e-only behaviour gap in the same function (the !retryIf(pr) short-circuit never reached end-to-end) is covered by #465.
Priority
- Impact: low
- Effort: low
Filed by quality agent (hold-gated mode)
🐝 Hive Agent: quality | Instance: hosted-available-lke648397-260827-5q9t | SHA: 7f01721
— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
Activity
github-actions commentedon Oct 13, 2026
Please add a kind label with
/kind failing-testor/kind cleanup.hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: isOwnReview's user-token arm (approveReview.ts:63, login === identity.login) never reached from dist/index.js
Finding
npm run test:coverage:e2e(main @ 7f01721, local run) leaves one arm ofisOwnReviewinsrc/plugins/approveReview.tsunreached end-to-end:coverage-e2e/lcov.infoforSF:src/plugins/approveReview.ts:BRDA:63,5,0,9 BRDA:63,5,1,0— the installation-token fallback (isBotUser) is taken 9×, the user-token comparison 0×.DA:35,1showsGET /usersucceeds in exactly one bundle run (approveReview.test.ts→ "does not even try when the token is a user who opened the pull request"), and that run routes no reviews, soisOwnReviewis never called with a marker review under an identified token. The unit suite does reach the arm (coverage/lcov.info:BRDA:63,5,1,4).The docstring of
syncApprovalReviewpromises "Reviews without the marker, or by anyone else, are never touched"; for a PAT/user token "anyone else" is decided by this login comparison, and nothing exercises that throughdist/index.js: whether an existing marker review by the token's own login suppresses resubmission, whether a bot's marker review is (correctly) not treated as own once the token has a login, and whether/approve canceldismisses only the login-matching review.Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines, approveReview.ts 100% branch. E2E evidence:npm run test:coverage:e2eon the same revision — approveReview.ts 90.38% branch, arm above at 0. Both from a local run on the same checkout; lcov raw data read directly (not the table summary).Recommendation
Add a bundle scenario file routing
GET /user→200 { login }with marker-bearingAPPROVEDreviews present, asserting:POST /pulls/1/reviews,already carries the approval reviewdebuggithub-actions[bot]under the user token → not own; a fresh review is submitted/approve cancelwith both present →PUT …/reviews/<own>/dismissalsonlyPriority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:7f01721— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: approve.ignore_review_state is never set in any bundle scenario (approve.ts:380-381 arms at 0 from dist/index.js)
Finding
npm run test:coverage:e2e(main @ 7f01721, local run) shows that no bundle scenario ever setsapprove.ignore_review_state: true. Incoverage-e2e/lcov.infoforSF:src/plugins/approve.ts:The true arms of both ternaries are taken 0× end-to-end;
grep -rn ignore_review_state __tests__/bundlefinds nothing. The unit suite reaches them (coverage/lcov.info:BRDA:380,55,0,2,BRDA:381,57,0,3).docs/configuration.md:343anddocs/commands.md:214-215document the option: with it set,APPROVEDreviews add nobody andCHANGES_REQUESTEDreviews remove nobody, anddocs/commands.md:298promises that withoutgithub_reviewthe reviews are not read at all. None of those three promises is exercised throughdist/index.js.Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines, approve.ts 100% branch. E2E evidence:npm run test:coverage:e2eon the same revision — approve.ts 93.25% branch, the two arms above at 0. Both from a local run on the same checkout; lcov raw data read directly.Recommendation
Add a bundle scenario file with
approve:\n ignore_review_state: trueinprow.yaml, asserting throughdist/index.js:APPROVEDreview by a listed approver →#1 is not approved, noapprovedlabel, and noGET /pulls/1/reviewsat all/approvefollowed by aCHANGES_REQUESTEDreview →#1 is approved by bob,approvedadded, noDELETEgithub_review: trueas well (GET /user→ 403) → reviews are read for the mirror, still count for nobody, noPOST /pulls/1/reviewsPriority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:7f01721— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Two more findings folded here by the
dist/index.jsconsolidation, both fromnpm run test:coverage:e2eon main@7f01721:1.
approve.ignore_review_statenever set in any bundle scenario —src/plugins/approve.tsBRDA:380,55,0,0/BRDA:381,57,0,0. The documented behaviour (docs/commands.md:214-215,298) is unit-tested only. A hold-gated PR adding__tests__/bundle/approveIgnoreReviewState.test.ts(3 scenarios) is open; see the linked PR.2.
effectiveKind's'ignore'arms atapprove.ts:228,230are unreachable fromdist/index.js— same shape as the arms #462 dropped for #458. With the setting on, line 381 already passes[]as the review list toapprovalEvents, so noreview-approved/review-changesevent can ever exist whensettings.ignore_review_stateis true.computeApprovalhas one production caller (approve.ts:382). Even with the new scenario file both arms stay atBRDA:228,33,0,0/BRDA:230,34,0,0. Production-code cleanup (drop the ternaries to plain'add'/'remove', repackdist/), so no PR from this lane:effectiveKindreview-approved→'add',review-changes→'remove'unconditionally; the unit cases reaching only the'ignore'arms removed;dist/repacked🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:3c70ee9— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: approvalEvents' non-APPROVED/CHANGES_REQUESTED review arm (approve.ts:125) never reached from dist/index.js
Finding
npm run test:coverage:e2e(main @ 7f01721, local run) leaves the fall-through arm ofapprovalEvents' review-state switch insrc/plugins/approve.tsunreached end-to-end:coverage-e2e/lcov.infoforSF:src/plugins/approve.ts:BRDA:125,15,0,1 BRDA:125,15,1,0—CHANGES_REQUESTEDis taken once, the else-arm (any other state:COMMENTED,DISMISSED,PENDING) never. The bundle suite does listCOMMENTED/DISMISSEDreviews (bundle.test.ts:718,approveMembershipArms.test.ts:83-84,approveReviewShortCircuits.test.ts:91,sweepArms.test.ts:142), but each is either the bot's review or has nosubmitted_at, so it is dropped by the guard on line 118 before the switch. The unit suite reaches the arm (coverage/lcov.info:BRDA:125,15,1,>0; approve.ts 100% lines, 98.87% branch there).docs/automatic-merging.md:398documents the contract: "GitHub reviews |APPROVEDadds an approver,CHANGES_REQUESTEDremoves one". That a human'sCOMMENTEDreview adds nobody, and that aDISMISSEDreview (a dismissed approval or a dismissed changes-request) neither adds nor withdraws, is exercised only by unit tests.Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines / 99.69% branch overall. E2E evidence:npm run test:coverage:e2eon the same revision — approve.ts 93.25% branch, arm above at 0. Both from a local run on the same checkout; lcov raw data read directly (not the table summary).Recommendation
Add a bundle scenario file on a
pull_request_reviewevent with human reviews carryingsubmitted_at, asserting throughdist/index.js:COMMENTEDreview by the covering approver →#1 is not approved; nobody approves sdk/x.go, noapprovedlabel, notifierNOT APPROVEDDISMISSEDreview by the covering approver → same: a dismissed approval is no approval/approvefollowed byCOMMENTEDandDISMISSEDreviews →#1 is approved by bob,approvedkept, noDELETE(contrast with the existingCHANGES_REQUESTEDscenario inbundle.test.ts:1748)Disjoint from #465 (
tide.tsretryIf), #467 (approveReview.ts:63) and #468 (approve.ts:380-381,ignore_review_state, which passes[]toapprovalEventsand so cannot reach this arm).Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:f62ea2d— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: canonicalCommand's dynamic remove-form arm (handleIssueComment.ts:91, e.g. /remove-triage) never reached from dist/index.js
Finding
npm run test:coverage:e2e(main @ 7f01721, local run) leaves the dynamic arm ofcanonicalCommandinsrc/issueComment/handleIssueComment.tsunreached end-to-end:coverage-e2e/lcov.infoforSF:src/issueComment/handleIssueComment.ts:BRDA:91,3,0,0 BRDA:91,4,1,0— thebaseconsequent is taken 0×, andisDynamicLabelCommand(base)is never even evaluated, so no bundle run ever lists a dynamic section's remove form (such as/remove-triage) inprow-commands. The only canonicalization scenario (commandCanonicalization.test.ts) uses/remove-help, which resolves through the alias table on line 84 before reaching line 90. The unit suite does reach the arm (coverage/lcov.info:BRDA:91,3,0,>0).docs/commands.md:14-15and:75document the contract: listing an alias enables the whole family, any other lower-case slash-key is a label command backed by the matching config section, and its remove form is enabled together with its base. Throughdist/index.jsnothing checks that configuring only/remove-triageenables/triage, that/remove-triageand/triagelisted together collapse to one run, or what a remove form with no matching section does.Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines, handleIssueComment.ts 100% branch. E2E evidence:npm run test:coverage:e2eon the same revision — handleIssueComment.ts 94.54% branch, the two arms above at 0. Both from a local run on the same checkout; lcov raw data read directly (not the table summary).Recommendation
Add a bundle scenario file with a
labels: triage: values: [accepted]section in.github/prow.yaml, asserting throughdist/index.js:prow-commands: /remove-triage+ comment/triage accepted→POST /issues/1/labels { labels: ['triage/accepted'] }prow-commands: /remove-triage+ comment/remove-triage accepted→DELETE /issues/1/labels/triage%2Faccepted, no POSTprow-commands: /remove-triage /triage→ duplicates collapse: exactly one label writeprow-commands: /remove-nosuchwith nonosuchsection → canonicalized to/nosuch, fails withnosuch: yaml malformed, expected 'nosuch' top level keyDisjoint from #465 (tide.ts retryIf), #466 (tide.ts:98), #467 (approveReview.ts:63), #468 (approve.ts:380-381) and #469 (approve.ts:125): none touch
handleIssueComment.ts.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:7f01721— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: merge-queue answers without an entry, enqueuer or error message (tide.ts:329-330,361; mergeQueue.ts:105,123,184) never driven from dist/index.js
Finding
npm run test:coverage:e2e(main @ 7f01721, local run,coverage-e2e/lcov.inforead directly — re-run with the heads of held PRs #465/#467/#468/#469/#470 merged in, so none of these arms is already claimed) leaves the merge-queue answers the shared fixture never gives unreached fromdist/index.js:The cause is in the fixture, not the scenarios:
__tests__/bundle/fakeGithub.tsmergeQueueRoutealways answers the enqueue mutation with{ state: 'QUEUED', position: 1 }and always wrapsentry.enqueuerin{ login }, so every bundle run sees a position and a named enqueuer. The unit suite reaches all six arms (coverage/lcov.info:BRDA:105,3,0,2,BRDA:123,4,0,3,BRDA:184,12,1,1, tideBRDA:329,44,0,>0).docs/automatic-merging.md:240documentsenqueued pr #<n> (position P)and:268the rule "only the bot's own entry (enqueuerisgithub-actionsor ends with[bot])" is ever dequeued. What happens when GitHub answers without an entry or without an enqueuer — the position is omitted rather than printed asundefined, and an entry with no enqueuer is treated as not-ours and left alone — is exercised only by unit tests.Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines / 99.69% branch, all six arms >0. E2E evidence:npm run test:coverage:e2eon the same revision plus the five held heads —mergeQueue.ts86.66% branch,tide.ts93.98% branch, the six arms above at 0. Both local runs on the same checkout.Not claimed:
mergeQueue.ts:188arm 1 (a non-Errorthrown byoctokit.graphql) —@octokit/graphqlonly throwsErrorsubclasses, so it is defensive and stays at 0.Recommendation
Add a bundle scenario file routing
POST /graphqlby operation (asmergeQueueArms.test.tsalready does for its HTTP-500 case), asserting throughdist/index.js:mergeQueueEntry: null→ exit 0, stdoutenqueued pr #1with no(position, noPUT …/mergepull_requestunlabeledlgtm withisInMergeQueue: trueandmergeQueueEntry.enqueuer: null→::debug::pr #1 was enqueued by an unknown actor; leaving it in the queue, nodequeuePullRequestdata: null, errors: []→ exit 1,could not enqueue pr #1: Request failed due to following response errors:Disjoint from #465 (
tideVerdictArms.test.ts, retryIf), #467, #468, #469 (approve*) and #470 (handleIssueComment.ts): none touch the GraphQL merge-queue path.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:7f01721— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: suggestApprovers' second greedy round (approve.ts:260) never reached from dist/index.js — the notifier never suggests two approvers end-to-end
Finding
npm run test:coverage:e2e(main @ 7f01721, local run, with the heads of held PRs #465/#467/#468/#469/#470/#471 merged in so none of their ground is counted) leaves the greedy set cover insuggestApprovers(src/plugins/approve.ts) one-round-only end-to-end.coverage-e2e/lcov.infoforSF:src/plugins/approve.ts:In every round the chosen
bestcovered every remaining file, so theremainingset always emptied after round one. No bundle scenario ever producesstate.suggestedwith more than one login: everyplease assignassertion in__tests__/bundle/names exactly one (**alice**,**bob**,**carol**), and nothing asserts the/assign @x @yform.The notifier's contract (
renderNotifier, approve.ts:296-300) is that a pull request spanning directories with disjoint approvers gets all of them listed —please assign **bob**, **carol**and/assign @bob @carol— with the most-covering approver first and ties broken alphabetically. That is unit-tested (__tests__/plugins/approve.test.ts:160"suggests approvers greedily…") but never observed throughdist/index.js.Unit evidence:
npx vitest run --coverageon main@7f01721 — approve.ts 100% lines / 100% branch. E2E evidence:npm run test:coverage:e2eon the same revision (+ held heads above) — arm above at 0. Both local runs on the same checkout; lcov raw data read directly (not the table summary, which ncc's column-less source map can misreport — #424).Recommendation
Add a bundle scenario file
__tests__/bundle/approveSuggestionArms.test.tsasserting throughdist/index.json apull_request_reviewevent:OWNERSwith reviewers only,sdk/OWNERS: [bob],olm/OWNERS: [carol], files in both →please assign **bob**, **carol**,/assign @bob @carol, both OWNERS files bold in the details lista/[x,y],b/[y,z],c/[z](allno_parent_owners) →please assign **y**, **z**,/assign @y @z,xnever suggestedDisjoint from #465 (
tide.tsretryIf), #466 (tide.ts:98), #467 (approveReview.ts:63), #468 (approve.ts:380-381,ignore_review_state), #469 (approve.ts:125, review-state arm), #470 (handleIssueComment.ts:91) and #471 (merge-queue nulls): none touchsuggestApproversor assert a multi-login suggestion.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:06d4d6c— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 13, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 63 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-e2e: tide.labels is never configured in any bundle scenario (tide.ts:542 probe-skip arm at 0 from dist/index.js)
Finding
npm run test:coverage:e2e(main @ 7f01721, local run) shows that no bundle scenario ever configures a validtide.labelslist. Incoverage-e2e/lcov.infoforSF:src/plugins/tide.ts:loadTidetakes the "labels undefined → probe the base branch for OWNERS" arm 367× and the "labels configured → skip the probe" arm 0×.grep -rn 'labels:' __tests__/bundleunder atide:key finds onlyconfigSchemaArms.test.ts:57, which is the schema-error case ([lgtm, ""]) and throws beforeloadTideruns. ConsequentlymeetsMergeGate'smissing <pattern>reason is reached end-to-end only from the default[lgtm]/[lgtm, approved]lists, never from a configured pattern (wildcard, mixed case). The unit suite reaches the arm (coverage/lcov.info:BRDA:542,83,1,4;__tests__/plugins/tide.test.ts:840routestide:\n labels: [lgtm]with an OWNERS tree and asserts it is not read).docs/automatic-merging.md:317-340documents three promises for a configured list, none exercised throughdist/index.js: every entry "must be present"; "A configured list replaces the default list, it does not extend it"; and the OWNERS tree listing is "skipped entirely whentide.labelsis configured".Unit evidence:
npx vitest run --coverageon main@7f01721 — 100% lines / 99.69% branch, tide.ts 100% branch at line 542. E2E evidence:npm run test:coverage:e2eon the same revision — tide.ts 93.98% branch, arm above at 0. Both from a local run on the same checkout; lcov raw data read directly (not the table summary).Disjoint from #465 (
tide.tsretryIf short-circuit,tideVerdictArms.test.ts), #466 (tide.ts:98initialfallback, production change), #471 (merge-queue nulls,mergeQueueNullArms.test.ts) and the approve*/handleIssueComment clusters (#467–#470, #472): none configuretide.labelsor assert on the OWNERS probe being skipped.Recommendation
Add a bundle scenario file on a
pull_requestlabeledevent withtide:\n labels: […]inprow.yaml, asserting throughdist/index.js:labels: [lgtm, approved]on a PR carrying onlylgtm→skipping pr #1: missing approved, noPUT, and noGET /git/trees/master?recursive=truelabels: [lgtm]on a base whose tree carries a rootOWNERS→merged pr #1and the tree is never read (the list replaces the[lgtm, approved]default)labels: [LGTM, "size/*"]on a PR withlgtm+size/M→ merges (case-insensitive,*spans/);[lgtm, "size/*"]on a PR with onlylgtm→skipping pr #1: missing size/*Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:7f01721— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
70 remaining items
hivecommons-hive commentedon Oct 16, 2026
Reopened by a person after #496 merged. Hive will not close this issue for #496 again; close it by hand or with a new PR.
hivecommons-hive commentedon Oct 16, 2026
🛠️ Hive agent
quality(hive hosted-available-lke648397-260827-5q9t) started work on this issue at 2026-10-16T19:45:37Z. A pull request referencing this issue supersedes this mark; it lapses on its own at 2026-10-16T21:45:37Z if none appears.hivecommons-hive commentedon Oct 16, 2026
Status check against the four items left open in the reopen comment, measured on
main @ 1062ce7(npm ci && npm run test:coverage:e2e, local run, 78 files / 487 tests passed; raw data read fromcoverage-e2e/lcov.info):owners.ts:127-147—expandGroupsteam arms already landed. The merged feat(owners): support GitHub groups in OWNERS #486 ships__tests__/bundle/ownersGroups.test.ts(4 scenarios: team-only reviewer authorized with the team read once + other-org/malformed warnings, root-OWNERS team on an issue, direct login next to a team without a team read, unreadable team refused with one warning).src/utils/owners.tsnow reads 100 / 100 / 100 / 100 in the e2e report;lcov.infohas noDA:…,0orBRDA:…,0underSF:src/utils/owners.ts. The folded finding was measured on the PR head05f387b, before that file was added. No further test work remains for this item.approve.ts:228,230— stillBRDA:228,33,0,0/BRDA:230,34,0,0(effectiveKind's'ignore'arms forreview-approved/review-changes).approve.ts:415— stillBRDA:415,69,1,0(existing.body ?? ''inupsertNotifier;existingis found via(comment.body ?? '').includes(notifierMarker), sobodyis never nullish there).meow.ts:88— stillBRDA:88,8,1,0(response.status || 'a redirect').The three remaining items are production-code removals (same shape as #462 for #458), so the quality lane does not open a PR for them — they need a maintainer or a lane permitted to change
src/and repackdist/. The tracker stays open for those three.Posted by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:1062ce7— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 16, 2026
Verification on
main@1062ce7(after #492 and #496 merged), local run,coverage-e2e/lcov.inforead directly:Box 1 —
initialrequired, line-98 fallback removed,dist/repacked: landed by #492 (merged 2026-10-16T18:37Z,1062ce7).src/plugins/tide.ts:60is nowinitial: Mergeability(no?), andtide.ts:98readslet pr = options.initial—grep -n getPull src/plugins/tide.tshas no hit insidefetchMergeability.Box 2 —
npm run test:coverage:e2eno longer liststide.ts:99:The remaining branch zeros on
tide.ts(137-138 non-Error/non-statusthrow in the merge catch, 258compared.data.files ?? [], 426data.draft ?? false) are unrelated defensive arms, not this finding.Both deliverables are done on
main; nothing further to implement here. The task list is only ticked by a human editing the body, so this stays open until a maintainer ticks both boxes or closes it.🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:1062ce7— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
Checked both task-list items against current
main(1062ce7, which includes #492 and #496), local run:Box 1 —
FetchMergeabilityOptions.initialrequired; line-98 fallback removed;dist/repackedsrc/plugins/tide.ts:60is nowinitial: Mergeability(required) and line 98 islet pr = options.initial— no?? await getPull(...)remains (grep -n getPull src/plugins/tide.ts→ lines 105, 180, 420, 438 only). Landed by #492.Box 2 —
npm run test:coverage:e2eno longer liststide.ts:99npm run test:coverage:e2eon 1062ce7: 78 files / 487 tests pass;tide.tsreports100 Stmts / 97.79 Branch / 100 Funcs / 100 Lines, Uncovered Line #s137-138,258,426. Incoverage-e2e/lcov.infoforSF:src/plugins/tide.tsnoDA:<n>,0entry exists; the only zero arms areBRDA:137,BRDA:138,BRDA:258,BRDA:426— all?? null/?? false/?? []defaults on API fields, unrelated tofetchMergeability. Line 99 is no longer named.Nothing in this issue's scope is outstanding. Both boxes can be ticked; this is left for a maintainer since only a human edit ticks them.
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:unknown— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
🛠️ Hive agent
quality(hive hosted-available-lke648397-260827-5q9t) started work on this issue at 2026-10-17T02:00:35Z. A pull request referencing this issue supersedes this mark; it lapses on its own at 2026-10-17T04:00:35Z if none appears.hivecommons-hive commentedon Oct 17, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 41 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] tide/sweep optional-field folds (tide.ts:258,426; sweep.ts:141) only run under the unit suite
Finding
Three nullish folds on optional GitHub REST fields are unit-covered but never executed by the bundle e2e suite (
npm run test:coverage:e2e,__tests__/bundledrivingdist/index.js):src/plugins/tide.ts:258—explainForkWorkflows:(compared.data.files ?? [])when a compare response omitsfilessrc/plugins/tide.ts:426—getPull:data.draft ?? falsewhen a pull request response omitsdraftsrc/cronJobs/sweep.ts:141—approveIfTrusted:(pr.labels ?? []).some(...)when a listed pull request omitslabelsEvery existing bundle case serves those fields populated, so the production shape where GitHub leaves them out (both are optional in the REST schema) is only exercised against unit fixtures.
Evidence
npm run test:coverageonmain@ 1062ce7 — all three branches taken (coverage/lcov.infohas noBRDA:…,0for these lines).npm run test:coverage:e2eonmain@ 1062ce7 —coverage-e2e/lcov.info:SF:src/plugins/tide.ts BRDA:258,27,1,0,BRDA:426,63,1,0;SF:src/cronJobs/sweep.ts BRDA:141,14,1,0. 78 files / 487 tests, Branches 97.96% (1633/1667).Recommendation
Add one bundle test file (
__tests__/bundle/tideOptionalFields.test.ts) driving each fold throughdist/index.js: apull_requestlabeled lgtm whoseGET /pulls/1has nodraft; a schedule lgtm fork-403 whose compare has nofiles; a schedule sweep whose listing item has nolabels.filesdraftlabelsDisjoint from #497 (approve.ts / meow.ts).
Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:1062ce7— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 41 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] 17 non-Error rejection normalizer arms are unreachable from dist/index.js: drop them or accept as unit-only
Finding
After #497 and #498, every remaining branch the bundle e2e suite (
npm run test:coverage:e2e, main @ 1062ce7,coverage-e2e/lcov.info) leaves untaken in the error-handling paths is the same shape: theelsearm ofe instanceof Error ? e.message : String(e)(or'status' in e/typeof e === 'object') for a rejection that is not anError:src/run.ts:40src/cronJobs/labelSync.ts:107,src/cronJobs/sweep.ts:132src/issueComment/handleIssueComment.ts:217(normalizeError),src/issueComment/trigger.ts:323(statusOf)src/labels/lgtm.ts:68src/plugins/approveReview.ts:226(errorStatus),:230(errorMessage),src/plugins/requireMatchingLabel.ts:167,src/plugins/tide.ts:137-138src/utils/auth.ts:14,17,24(getErrorDetails),src/utils/config.ts:657,src/utils/events.ts:50,src/utils/mergeQueue.ts:190Through
dist/index.jsevery rejection these catch comes from Octokit (RequestError, anError),js-yaml(YAMLException, anError), orfetch(TypeError). No fake-GitHub response can make the runtime throw a string or a plain object, so no bundle test can take these arms; the unit suite reaches them only by throwing literals directly.Evidence
npm run test:coveragemain @ 1062ce7 — all arms taken.npm run test:coverage:e2emain @ 1062ce7 — each of the above appears asBRDA:<line>,…,1,0incoverage-e2e/lcov.info;src/utils/auth.tsadditionallyDA:24,0.Decision needed
Same question #466's reopen comment settled for
approve.ts/meow.ts, now for the normalizers. Either:(e as Error).message/ unconditionale.messagewhere the catch only ever sees Octokit errors, and remove the unit cases that throw literals. Reaches 100% e2e branch on these files./* v8 ignore next */in the e2e config (or accept the standing delta) and close this.The quality lane only ships test code, so option 1 needs a maintainer or another lane. Reply with
/hive decision 1or/hive decision 2.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:a577c89— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 5 closed as completed in the last 14 days) already cite
coverage/lcov.info, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-reporting: unit and e2e lcov carry negative BRDA counts for 4 implicit-else arms after a conditional await (ast-v8-to-istanbul#207); text report names 4 phantom uncovered lines
Finding
Both coverage artifacts on
main @ 1062ce7contain negative branch hit counts, which the lcov format does not allow (aBRDAcount is a non-negative integer or-):All six are the implicit
elseof anifwhose condition is the result of a conditionalawait— the exact shape of the open upstream report AriPerkkio/ast-v8-to-istanbul#207 (filed 2026-10-14, reproduced with a rawnode:inspectorcapture, no Vitest involved; we pullast-v8-to-istanbul@1.0.6via@vitest/coverage-v8@5.0.3):The arms are not uncovered. The line after each
ifblock — the first statement of the else path — has a positiveDAcount in both suites (unitDA:40,12,DA:37,9,DA:504,7,DA:221,94; e2eDA:40,2,DA:37,3,DA:504,29,DA:221,48), and the bundle suite asserts on those paths directly (__tests__/bundle/defaultBranchFallback.test.ts:50→approve: the base branch has no OWNERS files;__tests__/bundle/triggerTestAndLgtmCancel.test.ts:199→stranger is not a org member or collaborator). The unit suite has explicit cases for each (close.test.ts:55,reopen.test.ts:55,approveEvents.test.ts:237,auth.test.ts). Re-runningvitest run --coverage __tests__/issueCommentTest/close.test.tsalone still yieldsBRDA:39,3,1,-2, so it is not a worker-merge effect.What it does to our numbers
textreporter listsclose.ts:39,reopen.ts:36,approve.ts:503,auth.ts:220under "Uncovered Line #s". Onlyapprove.ts:415is genuinely untaken (that one is refactor(approve, meow): drop the three dead arms left open on #466 #497's).coverage-summary.json→ the### Coveragestep summary intest.ymlreads 1662/1667 branches (99.7%); the true figure is 1666/1667. The e2e summary reads 1633/1667 (97.96%); true is 1635/1667.coverage-*artifacts uploaded bytest.ymlare not spec-valid lcov, so a strict consumer (Codecov-style parsers,lcov --summary) may reject or misreport them.No
coverage-gapfinding is attached to any of these four sites.Recommendation
This is upstream tooling, not something a test or workflow change in this repository can correct, so no PR accompanies this issue.
ast-v8-to-istanbulships a fix for [quality] uncovered error branches in run.ts, utils/config.ts fetch paths, utils/comments.ts createCommentOnce and labels/prefixed.ts #207, bump@vitest/coverage-v8and confirmgrep -E 'BRDA:.*,-[0-9]+$' coverage/lcov.info coverage-e2e/lcov.infois empty on both runs.BRDAentries as this artifact, not as gaps; the four lines above should not spawn scenario work.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:1062ce7— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
Closing out the e2e-zero catalog on main @ 1062ce7 (
npm run test:coverage:e2e,coverage-e2e/lcov.inforead directly). After #497, #498 and the normalizer-arms decision above, exactly two zero-count arms were not yet named on this tracker:1.
src/utils/command.ts:23—getLineArgs's?? ''is unreachable fromdist/index.jsby construction.BRDA:23,0,0,26 BRDA:23,0,1,0(unit:BRDA:23,0,1,3). Its only callers aremilestone.ts:43andretitle.ts:31, and the dispatcher (handleIssueComment.ts:128) runs either handler only afterhasCommand(form, body)— which isfindCommandArgs(...).length > 0, the same matchgetLineArgsperforms — returned true. Neither/milestonenor/retitlehas an alias incommandAliases, so the form that matched is the onegetLineArgsis called with, and.at(-1)is always defined. Same shape as theapprove.ts:415arm #497 drops: production cleanup (findCommandArgs(command, body).at(-1) as string, or makegetLineArgstake the already-matched args) plus the unit case that calls it with an absent command; no PR from this lane.getLineArgs?? ''arm removed,dist/repacked;BRDA:23no longer listed underSF:src/utils/command.tsincoverage-e2e/lcov.info2.
src/issueComment/approve.ts:94—String(context.payload.issue?.user?.login ?? '').BRDA:94,6,0,30 BRDA:94,6,1,0(unit:BRDA:94,6,1,1). A?? ''onissue.user.login, a field GitHub always sends — the class the d93ecb8 comment above already lists as not worth a scenario. Noted here only so the catalog is complete.Separately, the four negative
BRDAentries in both lcov files (close.ts:39,reopen.ts:36,approve.ts:503,auth.ts:220) are a reporter artifact (ast-v8-to-istanbul#207), not gaps; filed as its owncoverage-reportingissue.🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:1062ce7— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88
hivecommons-hive commentedon Oct 17, 2026
Folded finding. This was filed as a separate issue, but 1 open agent-filed issue (plus 41 closed as completed in the last 14 days) already cite
dist/index.js, so it was folded into the oldest of them instead of opening another. Treat this issue as the tracker for that component: prefer one structural fix that covers every folded variant over a PR per variant.[quality] coverage-reporting: the e2e regression floor (99/95/98/99) now sits 49 branches and 10 functions under what main reaches
Finding
vitest.e2e-coverage.config.mjsgatesnpm run test:coverage:e2eat 99 / 95 / 98 / 99 (lines / branches / functions / statements). #484 set those "just under whatmainreaches" when main measured 99.54 / 96.25 / 98.79 / 99.56 (d93ecb8). Since then the bundle scenarios in #467–#496 landed and main now measures:So a bundle scenario that stops driving up to 49
src/branches or 10 functions throughdist/index.jsstill passes the e2e run, which is exactly the regression the floor exists to catch. The functions floor in particular was set when sixreset*()hooks were unreached; #483 marked thosev8 ignore, and the figure has been 100 % since.Evidence (both suites run locally at
main@1062ce7, Node $(node --version)):npm run test:coverage→ 100 / 99.7 / 100 / 100; the only zero-count arm isapprove.ts:415(owned by held PR refactor(approve, meow): drop the three dead arms left open on #466 #497)npm run test:coverage:e2e→ 99.95 / 97.96 / 100 / 99.96; all 33 remaining zero-count arms are already catalogued on [quality] coverage-e2e names tide.ts:99 uncovered; the zero is the never-reachedoptions.initial ?? await getPullfallback on line 98 #466 or occupied by held PRs refactor(approve, meow): drop the three dead arms left open on #466 #497/test(bundle): drive tide's draft/files folds and sweep's labels fold through dist/index.js #498 — no new coverage gap, this is the reporting floor onlydocs/contributing.md:50documents the same 99 / 95 / 98 / 99 values and needs the same update.Recommendation
Apply the repository's own rule (#202, #484, #500: a floor just under what main reaches):
vitest.e2e-coverage.config.mjscoverage.thresholds:branches: 95 → 97,functions: 98 → 99(lines/statements stay 99); update the comment to record the figure it was set underdocs/contributing.md:50: "Fails below 99 % lines / 97 % branches / 99 % functions / 99 % statements"That leaves ~16 branches / ~5 functions of budget for an
ncc/vitestbump that shifts source-map attribution, the same margin #484 chose.Disjoint from held PR #500 (unit floor,
vitest.config.mjs+docs/contributing.md:48):git merge-treeof the two heads merges cleanly.Priority
Filed by quality agent (hold-gated mode)
🐝 Hive Agent:
quality| Instance:hosted-available-lke648397-260827-5q9t| SHA:02c284a— hive: agent=quality backend=copilot model=claude-fable-5.1 copilot=1.0.88