Pipelines page: one pipeline by tier and stage, and its delivery on each node

The operator read every step of main.417 as passed and took it for delivered
while it had failed on one step and no want was written: the page listed a
pipeline's steps flat, with no tier, no stage and no delivery. One pipeline now
shows a header (outcome, first failure's why, how many movers run their build
on every node they are placed on), then a block per tier with a row per mover,
a cell per stage (the worst outcome over its artifacts, waited, ran and why on
hover) and a cell per node its module is placed on (no want written, wanted,
applying, running the pipeline's build, held with why), in the web page and the
terminal view. The page reloads on the runner's events and on the wants',
haves' and assignments' changes the view already hears.

Builds: design 47 H2 H-A-531, H-A-531 addendum (hq 7dc6592b, f870d24b)
This commit is contained in:
2026-11-23 10:56:14 +01:00
parent 8a21bf5e96
commit 81387d0f3b
9 changed files with 598 additions and 38 deletions
@@ -17,7 +17,6 @@ import (
"text/tabwriter"
"time"
seat "git.novox.be/novox/mesh-delivery/modules/mesh-delivery-contracts/go/seats/meshpipelinerunner"
"mesh-delivery-view/internal/view"
)
@@ -148,8 +147,8 @@ func pipelines(socket string, args []string, next string, limit int, follow, asJ
return 0
}
// seatShow is the seat's answer of show, as the view hands it on.
type seatShow = seat.ShowAnswer
// seatShow is the view's answer of one pipeline: show's, with the pipeline's page by tier and stage naming no mover.
type seatShow = view.PipelineAnswer
// holds prints every hold: module, fingerprint, node, since, answer, words.
func holds(socket string, asJSON bool, out, errOut io.Writer) int {
@@ -306,7 +306,8 @@ func rawAsk(t *testing.T, a oc.Ask) json.RawMessage {
const testView = "acme-view"
// Design 47 H2 H-A-467: the terminal view's pipelines page: a branch's newest pipelines, and one pipeline's mover rows.
// Design 47 H2 H-A-467, H-A-531: the terminal view's pipelines page: a branch's newest pipelines, and one pipeline by tier and
// stage.
func TestThePipelinesCommands(t *testing.T) {
m := view.New(testView)
call := func(key string, body any) (json.RawMessage, error) {
@@ -346,7 +347,8 @@ func TestThePipelinesCommands(t *testing.T) {
{[]string{"pipelines", "next"}, "next.3 3 2 passed 1 4 0 0 0 0 0 0 0"},
{[]string{"pipelines", "next"}, "next.2"}, // the newest 20 by default
{[]string{"-limit", "1", "pipelines", "next"}, "next.3"},
{[]string{"pipeline", "next.3"}, "alpha src2:aa 0.2.1 passed"},
{[]string{"pipeline", "next.3"}, "TIER 1 MOVER OUTCOME BUILD LINT UNIT INTEGRATION VALIDATE COMPOSITION CODE REVIEW APPROVAL alpha passed - - - - - - - -"},
{[]string{"pipeline", "next.3"}, "PIPELINE next.3: passed; 0 of 1 movers run their build on every node they are placed on; 1 is placed on none"},
{[]string{"-json", "pipeline", "next.3"}, `"fingerprint": "src2:aa"`},
} {
var out, errOut bytes.Buffer
@@ -896,7 +896,7 @@ func TestProcessWholeSaysTheSourceRevisionIsDelivered(t *testing.T) {
pipelines.set(pseat.PipelineRow{Pipeline: "release.9", Source: rev, Revision: 9, Outcome: "passed", MoverCount: 1},
pseat.PipelineRow{Pipeline: "release.8", Source: rev, Revision: 8, Outcome: "superseded", MoverCount: 1})
var seen [][]string
err = view.AskPipelines(env["MESH_DELIVERY_SOCKET"], catalogBranch, 0, "", "", "", true, func(page view.PipelinesPage, _ *pseat.ShowAnswer) bool {
err = view.AskPipelines(env["MESH_DELIVERY_SOCKET"], catalogBranch, 0, "", "", "", true, func(page view.PipelinesPage, _ *view.PipelineAnswer) bool {
var keys []string
for _, r := range page.Rows {
keys = append(keys, r.Pipeline)