Repository navigation
feat(#1504): a dropped error leaves a trace — noteSuppressed() counts into the run log, batch-executor's 25 silent catches converted - #1564
Merged
admarble merged 4 commits intoOct 20, 2026
Conversation
Entire-Checkpoint: c7d1e4ff940c
Entire-Checkpoint: 66bacc18e714
… same class as the converted catches) Entire-Checkpoint: 6ec69a855491
6 tasks
…rted catches + updateAutoWait) Entire-Checkpoint: 04cef4900f08
3 tasks
admarble
deleted the
feature/1504-feat-run-a-dropped-error-leaves-a-trace-notesuppre
branch
October 20, 2026 02:53
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
The run now counts every error it drops.
src/lib/workflow/suppressed.tsaddsnoteSuppressed(scope, err, context?): it counts by scope, writes one line to stderr when verbose, and never throws.LogWriter.initialize()resets the count andfinalize()writessuppressed: { total, byScope }into every run log,total: 0included. The field is optional, so the schema staysversion: 1. All 25 empty catches inbatch-executor.tsnow call it, and each still continues as before.Pre-PR AC Verification
suppressed.test.ts: 5 passedgrep -c suppressed run-log-schema.ts→ 1; schema test: old logs still parseversion: z.literal(1)unchangedhealth-report --json→ 0fsmock--checkexits 0;emptyCatch.total→ 92 (≤ 94)Baseline rise recorded:
functions.longest.lines1050 → 1071 (runIssueWithLogging). Each of its 21 converted catches gains one code line; the metric skips comment-only lines, so this cannot be avoided without touching more than the catch bodies.Mutation-verified: AC-5 — deleted every
noteSuppressed("state"…)call; the state test failed; restored.Mutation-verified: AC-5 — deleted every
noteSuppressed("progress"…)call; the progress test failed; restored.Mutation-verified: AC-1 — removed the try guard around the sink; the never-throws test failed; restored.
Also: dropping the directory chmod (only
state.jsonat 0444) fails the AC-5 state test, and deletingfinalLog.suppressed = …fails both AC-5 tests.Files changed
suppressed.ts,suppressed.test.ts,batch-executor.suppressed.integration.test.ts,docs/adr/0018-suppressed-error-counter.md(Proposed)batch-executor.ts(catch bodies plus one import),log-writer.ts,run-log-schema.tsand their tests,health-baseline.json,docs/adr/README.md,CHANGELOG.md(### Added)Checks
npm run build✅ ·npm run lint✅ ·npm run lint:health✅ ("no metric rose above the baseline") · knip: nothing newSEQUANT_*unset:npx vitest run --changed origin/mainas 3 shards, 114 files, 2,345 tests, all passed.tautology-detector-cli.test.tsand both new test files: 11 files, 170 tests, all passed.Pre-PR Confidence Check
Quality Plan
Fixes #1504
Runner verification (2026-10-19)
The runner re-ran AC-1..AC-6 verbatim:
11092batch-executor,suppressedand the integration file pass.AC-5 mutation repeated: deleting every
noteSuppressed("state"…)call fails the state fault-injection test. Restored.Added by the runner:
updateAutoWait(...).catch(() => {})dropped a state error uncounted (QA's open finding). It now callsnoteSuppressed("state", err, "updateAutoWait"). There is no direct test: the auto-wait path needs a live wait.Owner ruling (2026-10-19):
functions.longest.linesrises from 1050 to 1072. Each of the 21 converted catches gains one code line, plus 1 for the fix above. This is accepted in exchange foremptyCatch.totalfalling from 117 to 92. #1506/#1507 splitrunIssueWithLoggingnext. ADR-0018 is Proposed; acceptance is the owner's (D-4).🤖 Generated with Claude Code