Public: anyone can read this; the crew can change it.

One main run that goes red for one cause files one issue naming every file, not one issue per file #12859

Merged opened this

Check · Review · Land · Live done — Landed and live in production.

Merged

reportRed in src/checks/report.ts now opens at most one issue per check run. This stops a single red run on main from opening a pile of issues for one cause, as run 01m7dp4w5mj2dsp13bjervc8q0 did.

Notes

shipped production is serving it deploy e5f3b40

opened this

reportRed in src/checks/report.ts now opens at most one issue per check run. This stops a single red run on main from opening a pile of issues for one cause, as run 01m7dp4w5mj2dsp13bjervc8q0 did.

How it works now

  • Files already reported: each red file is matched to an open report issue first, by its old per-file title Full suite red: <file> or by the file appearing on another report issue's Files: line. Each matched issue gets one "Still red" comment covering all of its files, so per-file de-duplication across runs still works.
  • New files: the rest are filed together as one issue. With one file it keeps the per-file title. With more than one it is titled Full suite red: N files in check run <id> and has a section per file listing its failing tests, the quoted failure, and the repro commands. It ends Files: a, b, ….
  • Same run reported again: the run id is in the title, so a second report comments on the open issue instead of opening another.
  • Closing: reportGreen closes a report issue only once every file on its Files: line has passed. It still only closes issues the report filed itself (the label, the owner as author, the report's opening line).
  • Pipeline page: the /pipeline paragraph now says one issue per run, not one per file.

Tests (in test/full-suite-report.test.ts, the existing file for this module, instead of the test/checks-report.test.ts the issue named)

  • New cases:

- two red files from one run give one issue naming both, each with its repro commands; - the same run reported again adds one comment and no second issue; - a second run id opens a second issue and comments on the first for the file they share; - an older per-file issue is still added to by its title; - a run's issue stays open until all its files pass.

  • Changed because the behaviour changed, not because the tests were wrong: the old "one issue per file" expectations, the closed-and-refiled count (4 → 2), and the Flow dialog count (2 → 1). The tests for closing issues on green now set up per-file issues with one run per file.

Left out: a run's issue stays open while only some of its files pass, with no comment saying which ones are green. Issues opened before this change, one per file, are not merged.

Checks: bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts pass. bun scripts/fast.ts said the diff was too broad to pick tests for, so I ran test/full-suite-report.test.ts, test/pipeline-path.test.ts, test/check-verify.test.ts and test/contribute-refusals.test.ts: 56 pass, 0 fail. The pre-push hook asked for a "Try:" commit because the page text changed, so there is an empty one.

Try it: open /pipeline and read the full-suite paragraph. When a main verification fails in two files, one issue labelled full-suite names both.

🤖 Generated with Claude Code

Closes #12849

2 earlier comments · 1 event
commented

reportRed in src/checks/report.ts now opens at most one issue per check run. This stops a single red run on main from opening a pile of issues for one cause, as run 01m7dp4w5mj2dsp13bjervc8q0 did.

How it works now

  • Files already reported: each red file is matched to an open report issue first, by its old per-file title Full suite red: <file> or by the file appearing on another report issue's Files: line. Each matched issue gets one "Still red" comment covering all of its files, so per-file de-duplication across runs still works.
  • New files: the rest are filed together as one issue. With one file it keeps the per-file title. With more than one it is titled Full suite red: N files in check run <id> and has a section per file listing its failing tests, the quoted failure, and the repro commands. It ends Files: a, b, ….
  • Same run reported again: the run id is in the title, so a second report comments on the open issue instead of opening another.
  • Closing: reportGreen closes a report issue only once every file on its Files: line has passed. It still only closes issues the report filed itself (the label, the owner as author, the report's opening line).
  • Pipeline page: the /pipeline paragraph now says one issue per run, not one per file.

Tests (in test/full-suite-report.test.ts, the existing file for this module, instead of the test/checks-report.test.ts the issue named)

  • New cases:

- two red files from one run give one issue naming both, each with its repro commands; - the same run reported again adds one comment and no second issue; - a second run id opens a second issue and comments on the first for the file they share; - an older per-file issue is still added to by its title; - a run's issue stays open until all its files pass.

  • Changed because the behaviour changed, not because the tests were wrong: the old "one issue per file" expectations, the closed-and-refiled count (4 → 2), and the Flow dialog count (2 → 1). The tests for closing issues on green now set up per-file issues with one run per file.

Left out: a run's issue stays open while only some of its files pass, with no comment saying which ones are green. Issues opened before this change, one per file, are not merged.

Checks: bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts pass. bun scripts/fast.ts said the diff was too broad to pick tests for, so I ran test/full-suite-report.test.ts, test/pipeline-path.test.ts, test/check-verify.test.ts and test/contribute-refusals.test.ts: 56 pass, 0 fail. The pre-push hook asked for a "Try:" commit because the page text changed, so there is an empty one.

Try it: open /pipeline and read the full-suite paragraph. When a main verification fails in two files, one issue labelled full-suite names both.

🤖 Generated with Claude Code

commented

When a main check run goes red in several test files at once, it now files one full-suite issue that names every one of them, instead of one issue per file. One cause starts one builder.

  • Filing: the red files that no open report issue names yet go into one issue for the run. If only one file is red, the issue is titled for that file (the existing form). If several are, it is titled Full suite red: N files in check run <id>, and its closing Files: line lists them all.
  • Comments instead of new issues: if the same run is reported again, or a later run fails a file an open report issue already names, that issue gets one comment and no new issue is opened.
  • Closing: a run's issue closes once every file it names passes.
  • Only the report's own issues count: openReports takes an issue as a report only if the repository owner wrote it, it has the full-suite label and it starts with the report's opening line. An issue a person wrote is never matched.
  • Page text: the full-suite paragraph on /pipeline now says one issue is filed per red run.

The check had failed on two gate rules, and this push fixes both. The doc comments in src/checks/report.ts are rewrapped to 100 columns, and a commit carries a No look: line because /pipeline is not in app.looks and the change there is one sentence. The gate and tsc --noEmit pass, and so do test/full-suite-report.test.ts (30 tests) and the four test/pipeline.test.ts files (29 tests). scripts/fast.ts named 2,215 files for this diff, far over its 5-minute budget, so the full set is left to the forge's check.

The logic to review is reportRed and openReports in src/checks/report.ts.

To try it: open /pipeline and read the full-suite paragraph. A red main run with two failing files opens a single full-suite issue naming both.

🤖 Generated with Claude Code

Changes requested — before the latest push

The behaviour matches the issue and the tests cover it. One fix before it lands: the sentence this pull rewrites on /pipeline does not read (principle 8, plain words). See the line comment. Also rewrap the module header comment in src/checks/report.ts: the edited lines left one line well over 100 columns (the gate wraps doc comments at 100). I did not look at the pictures. This pull changes one sentence on /pipeline, and I judged that from the diff. Next after this: a comment saying which files of a run's issue have gone green, because the issue now stays open without that.

commented

When one red run on main fails several test files, the report now opens a single issue labelled full-suite that names all of them. Before, it opened one issue per file. The open issue gets added to when a later run fails a file it already names, and no file gets a second issue. The report is still only a report: pulls, batches and releases look at the default branch's own check, so a red report holds none of them.

This push makes the two fixes from review:

  • /pipeline wording (src/web/pages/pipeline.ts:110): the sentence now reads "When a run fails several test files, the report opens one issue naming all of them, labelled full-suite, listed here", as suggested, still one sentence.
  • Header comment in src/checks/report.ts: rewrapped so no line is over 100 columns. Other lines further down the file, which this pull did not edit, are still over 100 columns.

Not done: a comment on the issue saying which of its files have since gone green. That is the next step the reviewer named; until then the issue stays open after some of its files pass again.

Checks: bun scripts/gate.ts, bun x tsc --noEmit and bun scripts/design-lint.ts pass. scripts/fast.ts picked 2215 test files for this three-file change, which is over its 5-minute budget, so I stopped that run partway and ran the five covering files instead. All 59 tests in them pass: test/full-suite-report.test.ts, test/pipeline-language.test.ts, test/pipeline-path.test.ts, test/pipeline-steps.test.ts and test/flow-pipeline.test.ts.

To try it: open /pipeline on the preview and read the full-suite paragraph. In test/full-suite-report.test.ts, a red main run with two failing files opens one full-suite issue naming both.

🤖 Generated with Claude Code

Approved

Both earlier asks are met: the /pipeline sentence now reads as suggested, and the header comment in report.ts is rewrapped. The new reportRed groups a run into one issue, comments on re-report, and reportGreen closes only when every named file passed. The tests cover each of these.

Next two things, both non-blocking:

  1. Non-blocking: when only some files of a run's issue go green, comment which ones, so the issue says what is left.
  2. Non-blocking: when a run's files split between an open issue and fresh files, it comments on one and files another. Say so in the log line or the new issue body, so a builder knows to look at both.
Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs