builds: name the failed step and duration; jump to failure !489

merged merged by cmc on 2026-09-28 22:33 UTC · krz/gitbay:build-failure-report into main

Discussion

cmc

A failed build names the step that failed and how long it ran.

  • Migration 0065: builds.failed_step, builds.failed_reason.
  • The runner writes step N/M failed: <reason> (exit status, timeout, cancellation) in both isolation modes and sends runner done <id> failure --step N --reason '…'. The server stores a bad --step as 0 rather than refusing, so an outcome is never lost.
  • build show prints failed step 3/3 go test ./... (exit 1) and duration; --json gains failed_step, failed_reason, duration_s, steps.
  • build log --step <n>|failed and --tail <lines> (neither with --follow), cut at the runner's $ <step> lines, so older logs split too.
  • The web build page folds the log into one <details> per step, the failed one open with id="failed" and a "Jump to failure" link; duration next to "finished"; pre.buildlog wraps at phone width. No JavaScript.
  • e2e, CI/Users/Parity/Architecture pages, CHANGELOG.

Deploy gitbayd before the runner: an older server refuses the runner's new --step flag. Validate on a scratch repository first (plan runbook R4).

Stacked on !484.

Closes #266