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

A pull's reviews, checks, logs and history open in place as folds, with no notes #16678

Merged opened this

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

Merged

A pull's own page now has one list under the verdict and the change, with reviews, checks and history as folded rows. The check log is a fourth folded row, nested inside Checks. Only a failing check opens on its own.

Notes

opened this

A pull's own page now has one list under the verdict and the change, with reviews, checks and history as folded rows. The check log is a fourth folded row, nested inside Checks. Only a failing check opens on its own.

I didn't produce before-and-after looks. The sandbox has no screenshots. bun scripts/design-lint.ts shows no new findings, bun x tsc --noEmit is clean, and bun scripts/gate.ts --fix changed nothing. I ran test/pull-verdict.test.ts and eight neighbouring suites (pull-quiet, studio-changes, studio-door-app-state, review-page, reviews-states, land-as-is, attention, offer-upstream, story-walk). They pass. I did not run the full suite.

What changed

  • Where it lives: the new module is src/web/studio/pull_folds.ts, wired into changeConversation in src/web/studio/change.ts. That is the pull's own page (the Change tab). I put it there, not in src/web/pages/pull.ts, which is the Files tab.
  • Reviews: closed, it reads like "2 reviews · 1 approved". Open, it lists every review.
  • Checks: closed, it shows the check word. Open, it shows the existing check line and live line, and the log tail nested as its own fold. #pull-check and its live region are kept, so live updates still work.
  • Log: the tail of the run's log, shown only to someone who may read that log. It links to the whole run.
  • History: the branch's commits, one row each.
  • Opening: when the head's check is red, Checks and its nested Log open. Reviews and History stay closed.
  • Reviews in the thread: a request for changes that is still waiting stays in the conversation as well as in the fold. Other reviews now appear only in the fold.
  • Test: in test/pull-verdict.test.ts, one test asserts the folds are present, all closed on a calm pull, and only Checks and Log open on a pull with a failing check. It also asserts no class="note" anywhere in the body.

Reused: row({fold}) and rowList from ui.ts, commitLog, readRunLogTail, mayReadRunLog, and reviewEntry for each review's drawing. scripts/similar.ts found nothing like the new module.

Left out

  • I removed no other prose from the page, such as the "Not ready to ship —" line and the draft explanation. They explain a decision. The page had no .note blocks to begin with.
  • The log fold shows the last 60 lines, not the whole log.
  • I added no CSS and no new component class.
  • The first push was refused by a pre-push hook that wants a Try: commit. I added an empty one: "open a pull's own page and open its Checks fold".

Try it: open any pull at /<owner>/<repo>/pulls/<n>. Below the verdict you'll see Reviews, Checks and History as closed rows, and a pull whose check failed opens Checks and its Log.

[
  {"go":"/alice/ready/pulls/1","look":"Below the verdict and the change: three folded rows (Reviews, Checks, History), all closed","expect":"Each shows a one-line summary and opens in place without a page load"},
  {"go":"/alice/held/pulls/1","look":"A pull whose check is red","expect":"Checks and its nested Log are open, showing the log tail; Reviews and History stay closed"}
]

🤖 Generated with Claude Code

Closes #10538

5 earlier comments
commented

A pull's own page now has one list under the verdict and the change, with reviews, checks and history as folded rows. The check log is a fourth folded row, nested inside Checks. Only a failing check opens on its own.

I didn't produce before-and-after looks. The sandbox has no screenshots. bun scripts/design-lint.ts shows no new findings, bun x tsc --noEmit is clean, and bun scripts/gate.ts --fix changed nothing. I ran test/pull-verdict.test.ts and eight neighbouring suites (pull-quiet, studio-changes, studio-door-app-state, review-page, reviews-states, land-as-is, attention, offer-upstream, story-walk). They pass. I did not run the full suite.

What changed

  • Where it lives: the new module is src/web/studio/pull_folds.ts, wired into changeConversation in src/web/studio/change.ts. That is the pull's own page (the Change tab). I put it there, not in src/web/pages/pull.ts, which is the Files tab.
  • Reviews: closed, it reads like "2 reviews · 1 approved". Open, it lists every review.
  • Checks: closed, it shows the check word. Open, it shows the existing check line and live line, and the log tail nested as its own fold. #pull-check and its live region are kept, so live updates still work.
  • Log: the tail of the run's log, shown only to someone who may read that log. It links to the whole run.
  • History: the branch's commits, one row each.
  • Opening: when the head's check is red, Checks and its nested Log open. Reviews and History stay closed.
  • Reviews in the thread: a request for changes that is still waiting stays in the conversation as well as in the fold. Other reviews now appear only in the fold.
  • Test: in test/pull-verdict.test.ts, one test asserts the folds are present, all closed on a calm pull, and only Checks and Log open on a pull with a failing check. It also asserts no class="note" anywhere in the body.

Reused: row({fold}) and rowList from ui.ts, commitLog, readRunLogTail, mayReadRunLog, and reviewEntry for each review's drawing. scripts/similar.ts found nothing like the new module.

Left out

  • I removed no other prose from the page, such as the "Not ready to ship —" line and the draft explanation. They explain a decision. The page had no .note blocks to begin with.
  • The log fold shows the last 60 lines, not the whole log.
  • I added no CSS and no new component class.
  • The first push was refused by a pre-push hook that wants a Try: commit. I added an empty one: "open a pull's own page and open its Checks fold".

Try it: open any pull at /<owner>/<repo>/pulls/<n>. Below the verdict you'll see Reviews, Checks and History as closed rows, and a pull whose check failed opens Checks and its Log.

[
  {"go":"/alice/ready/pulls/1","look":"Below the verdict and the change: three folded rows (Reviews, Checks, History), all closed","expect":"Each shows a one-line summary and opens in place without a page load"},
  {"go":"/alice/held/pulls/1","look":"A pull whose check is red","expect":"Checks and its nested Log are open, showing the log tail; Reviews and History stay closed"}
]

🤖 Generated with Claude Code

commented

<!-- look-pages b8305e90e36d --> Look pages for b8305e9, from the gate:

  • look pages (none): this pull changes src/web/studio/change.ts, src/web/studio/pull_folds.ts but the forge could not trace the route of /settings/security/controls (an inline or wrapped handler), so it could not infer a page; the reviewer decides. A "Looks: <path>" line naming the nearest page, or a "No look: <why>" line (10+ characters), says it
commented

A pull's reviews, checks (with their log) and history now open in place as folds, and only a red check opens on its own. The code was already pushed. This push only adds a commit message that satisfies the two gate rules that refused it. I ran bun scripts/gate.ts locally and it printed nothing, which I take as a pass. I did not re-run the type check or the tests, and the code is unchanged since the last push.

  • Name the issue: the commit carries Direction: … (#10538).
  • Both doors: the commit carries a No door: line. The folds live on the pull's web page, and the terminal already lists a pull's checks and history in its own screens. I did not add a terminal screen.
  • Look pages: the gate could not trace the pull page's route, and this is only a note, not a refusal. I added a No look: line instead of a Looks: path, so a reviewer should open any pull to see the folds.

To try it, open any pull's page on the preview at https://lab--16678--forge-trevato-apps.open-platform.sh.

Co-Authored-By: Claude Sonnet 5.5 <[email protected]>

commented

A pull's reviews, checks (with their log) and history now open in place as folds on its page, and only a red check opens on its own. This push fixes the 10 failing tests from the last check run. I re-ran the six test files that cover the failures, the type check and the gate here, and all pass. I did not run the full suite.

Two things were wrong:

  • Empty head: the History fold asked git for the log with an empty head id on pulls that have none, which gave a 500. These were the og-tags, public-head and page-head failures. It now skips the query when there is no head.
  • Studio vocabulary: the History fold said "commit", a word the studio pages never use, which failed the studio-words test. It now says "1 step" and "Nothing to show".

The "big JSON file" test failed in the check run but passes here, and this change doesn't touch it. I didn't find what made it fail there.

What I left out:

  • No terminal screen: the terminal already lists a pull's checks and history in its own screens.
  • No Looks: path, because the gate could not trace the pull page's route. A reviewer can open any pull to see the folds.

To try it, open any pull's page on the preview at https://lab--16678--forge-trevato-apps.open-platform.sh.

commented

The four points are fixed and pushed. The type check, gate, design lint and the five test files I ran (pull-verdict, thread-window, studio-words, og-tags, feature-orphans) pass. scripts/fast.ts named 3648 files, too many to run here, so the forge's check runs the rest. I did not look at the 360px width in a browser: the Log fold's CSS fix is untested at that width.

  • Both doors: the terminal already gives the same facts under the same gates, so I added no screen. docs/features/pull-folds.md names the screens and has the how-to.
    • Reviews: src/tui/screens/pull.ts and pull_review.ts.
    • Check log: runlist.ts opens a run in runlog.ts, which reads through runLog.
    • History: commits.ts.
  • Looks: the commit has Looks: /alice/held/pulls/1. The Log <pre> now scrolls sideways inside its own box (.card-body > pre in src/web/style/content.ts). The fold opens in place.
  • One way: a waiting request for changes now shows only in the Reviews fold, and I removed the thread copy. The closed fold says "asked for changes".
  • Tests: three new ones, all in test/pull-verdict.test.ts:
    • The summary words are right.
    • A pull with reviews lists them once, in the fold.
    • A viewer who may not read the log gets no Log fold and no log text.
  • Smaller:
    • The closed Checks summary now says "not run yet" for a check that hasn't run. I left the line above it, in the check status, saying "open": the live script reads it.
    • I dropped the duplicate .slice(-60).
    • I wrapped the kept line.
commented

I fixed the dead-code failure, and tsc and the affected tests are now green. The other two failures passed when I re-ran their files, so I treated them as flakes and changed nothing for them.

  • Dead code: standingRequests in src/web/studio/change.ts was exported but only its own test called it. Nothing under src/ used it, because the timeline entry's open flag is set where the entry is built. I removed the function, and its test and unused imports in test/thread-window.test.ts.
  • Flaky tests: "run.log frames on /events > a closed stream leaves no tap behind" and the blob page's switch test (in test/events-run-log.test.ts and test/media.test.ts) both pass here. Neither touches code this pull changes. They failed only in the shard run.
  • Checks run: bun x tsc --noEmit is clean, and thread-window, unused-exports, events-run-log and media tests all pass (52 tests). I did not run the whole suite; the forge's check does that on the push.
  • Gate: bun scripts/gate.ts --fix ran before the first push. I did not re-run it after the second commit, which only removed an import.

The first push had a leftover Review import that tsc rejected; the second push removes it.

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs