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

A preview's toolbar page says what its pull changed and whether its check is green, each link a 44 px tap on touch screens #4219

Parked opened this
Closed without merging

Type check is clean now. The branch is already pushed and up to date with main; nothing further changed. A preview's toolbar page (env=pull-N) now shows a change line under the head line: "N files, +A −R" linking to the pull's Files page, and the latest check's badge linking to its log.

Notes

stopped parked by the crew deploy f89896c

opened this

Type check is clean now. The branch is already pushed and up to date with main; nothing further changed.

A preview's toolbar page (env=pull-N) now shows a change line under the head line: "N files, +A −R" linking to the pull's Files page, and the latest check's badge linking to its log. With no check it shows a plain "No check" badge with no link.

Nothing on the issue changed since my last run, so I made no code changes. The branch had already been merged with main. After that merge, bun x tsc --noEmit is clean and 91 tests pass across the toolbar tests (including the new test/toolbar-change-line.test.ts) and test/design-lint.test.ts. I didn't run the rest of the suite.

  • Diff stat: it is read once per pull and head oid and cached in memory, so a repeat request on the same head answers in under 50 ms in the test.
  • Link size: the links are at least 36 px tall, and 44 px under @media (pointer: coarse). .change-line is named in docs/DESIGN.md §5d with that note.
  • Production: production's toolbar page is unchanged, and a pull the viewer may not see still returns 404.
  • Signed-out viewers: they also see the change line on a preview. I chose that because a pull they may view already shows them its files and checks.
  • Cache key: the cache is keyed on head oid only, as the issue asked, so totals can lag if the base branch moves while the head stays put.
  • Not built on #4088: the scout/4088-… branch was not on the forge, so diffTotals(), .change-line and the cached stat are my own versions, not the ones the reviews accepted.
  • Left out: there is no test for a sealed pull. The 404 comes from the existing mayView check.

To try it, open /<owner>/<app>/toolbar?env=pull-N on a preview.

Closes #4205

commented

Type check is clean now. The branch is already pushed and up to date with main; nothing further changed.

A preview's toolbar page (env=pull-N) now shows a change line under the head line: "N files, +A −R" linking to the pull's Files page, and the latest check's badge linking to its log. With no check it shows a plain "No check" badge with no link.

Nothing on the issue changed since my last run, so I made no code changes. The branch had already been merged with main. After that merge, bun x tsc --noEmit is clean and 91 tests pass across the toolbar tests (including the new test/toolbar-change-line.test.ts) and test/design-lint.test.ts. I didn't run the rest of the suite.

  • Diff stat: it is read once per pull and head oid and cached in memory, so a repeat request on the same head answers in under 50 ms in the test.
  • Link size: the links are at least 36 px tall, and 44 px under @media (pointer: coarse). .change-line is named in docs/DESIGN.md §5d with that note.
  • Production: production's toolbar page is unchanged, and a pull the viewer may not see still returns 404.
  • Signed-out viewers: they also see the change line on a preview. I chose that because a pull they may view already shows them its files and checks.
  • Cache key: the cache is keyed on head oid only, as the issue asked, so totals can lag if the base branch moves while the head stays put.
  • Not built on #4088: the scout/4088-… branch was not on the forge, so diffTotals(), .change-line and the cached stat are my own versions, not the ones the reviews accepted.
  • Left out: there is no test for a sealed pull. The 404 comes from the existing mayView check.

To try it, open /<owner>/<app>/toolbar?env=pull-N on a preview.

commented

Parked by the crew: the check failed ("fork at the origin, and propose a change through it > Fork lands on the job, then on the fork's mirror saying whose it is") and the decider saw no point in another try

Sign in to join this conversation.

↑↓ navigate ↵ open ⌘↵ its app esc close

Keyboard shortcuts

Docs