ParseContexttypetype ParseContext = { readonly module: string; readonly run: string; readonly commit: string; readonly step: string; readonly at: string };What a parser needs to know of the run and the step it reads.
The parsers that read what a tool printed into findings (commons 0038-build-policy FR-013): one function for each tool of the closed table, pure over the text the tool wrote, so that each is tested on real output kept in the test's fixtures. A parser reads what is there and makes nothing up; where a tool failed and printed nothing a parser can read, the wrapper makes the finding no-output of that tool, and a parser says nothing.
The key of a finding is the text that tells it from another of the same code in the same file and is never a line or a time, so that a finding that moves is the same finding (findingId). The tools' own formats: tsc (file(line,col): error TSnnnn: message), bun test ((fail) name [time], under a header line naming the file), the linter (<error|warning file= line= column= rule=> and the message), the formatter (a path for each file it would change), repoctl check ([x] where: message [E-CODE]), the checks of Mizan and Kanon (file:line: message, file:line: code: message) and the generator's check (file is not what the model makes).
import { parseOutput } from "./parsers.ts";
parseOutput("tsc", "a.ts(1,7): error TS2322: no", { module: "core", run: "1", commit: "c", step: "s", at: "2026-11-22T00:00:00Z" }).length; // 1ParseContexttypetype ParseContext = { readonly module: string; readonly run: string; readonly commit: string; readonly step: string; readonly at: string };What a parser needs to know of the run and the step it reads.
parseOutputfunctionfunction parseOutput(tool: "bun-test" | "checks" | "exit-status" | "format" | "generated-files" | "install" | "kanon-check" | "lint" | "mizan-check" | "policy" | "repoctl-check" | "tsc" | "verify", output: string, ctx: ParseContext): readonly Finding[]The findings a tool's output holds, with their ids and their evidence (the SHA-256 of the output), in the order the tool printed them and without a finding twice.
outcomeFindingfunctionno test imports itfunction outcomeFinding(tool: "bun-test" | "checks" | "exit-status" | "format" | "generated-files" | "install" | "kanon-check" | "lint" | "mizan-check" | "policy" | "repoctl-check" | "tsc" | "verify", code: "no-output" | "timeout" | "tool-error", message: string, ctx: ParseContext, output: string): FindingThe finding of a step that did not end as a tool does: it could not be started, it exited non-zero with nothing a parser reads, or the time limit stopped it (tool-error, no-output, timeout).