C-W2: a step the assigner serves names its asker

The seat mesh-wants' StepRun gains asker, the seat name of the part asking the step (the runner
writes mesh-pipeline-runner), so the assigner names a step's progress with it. Optional in the
definition: the line names its writer, not that a step without it is refused. Both accept:step
fixtures carry it; the generated fixture test fails without the field.

Builds: design 47 H §745; lead answer H-A-88 (hq 2c6c7c03), H-A-41

Claude-Session: https://claude.ai/code/session_01JG73KHUnBze48rdua8u2sy
This commit is contained in:
2026-11-20 03:27:41 +01:00
parent 87e9084e15
commit 3560362330
5 changed files with 14 additions and 4 deletions
@@ -1075,6 +1075,8 @@ const (
// StepRun is a pipeline step of one mover the assigner serves (design 47 H §745, G §22): validate, the manifest validator built from the take-in's heads run over the revision's manifests, before composition, each machine's declaration composed at the change's heads with the composer built from them, both in the build seat's sandbox.
type StepRun struct {
// the seat name of the part asking the step, mesh-pipeline-runner for the runner; the assigner names the step's progress with it (design 47 H-A-88, H-A-41)
Asker string `json:"asker,omitempty"`
// the watched branch, or the branch of a run on request
Branch string `json:"branch"`
// for a rerun, the caller the runtime proved
@@ -141,9 +141,9 @@ func TestFixtures(t *testing.T) {
decode: func(b []byte) (any, error) { var v DifferenceAnswer; err := json.Unmarshal(b, &v); return v, err }, subjectIs: nil},
{name: "difference refuses a changed fingerprint with no difference, by name", subject: "", given: "{\"changes\":[],\"from\":40,\"refused\":[{\"module\":\"xclip\",\"why\":\"its fingerprint changed and its difference is empty\"}],\"to\":41}", wire: "{\"changes\":[],\"from\":40,\"refused\":[{\"module\":\"xclip\",\"why\":\"its fingerprint changed and its difference is empty\"}],\"to\":41}",
decode: func(b []byte) (any, error) { var v DifferenceAnswer; err := json.Unmarshal(b, &v); return v, err }, subjectIs: nil},
{name: "a composition step asked by the runner", subject: "mesh.seat.mesh-wants.accept.step", given: "{\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"composition\"}", wire: "{\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"composition\"}",
{name: "a composition step asked by the runner", subject: "mesh.seat.mesh-wants.accept.step", given: "{\"asker\":\"mesh-pipeline-runner\",\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"composition\"}", wire: "{\"asker\":\"mesh-pipeline-runner\",\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"composition\"}",
decode: func(b []byte) (any, error) { var v StepAccept; err := json.Unmarshal(b, &v); return v, err }, subjectIs: regexp.MustCompile("^mesh\\.seat\\.mesh-wants\\.accept\\.step$")},
{name: "a validate step asked by the runner, before the mover's composition", subject: "mesh.seat.mesh-wants.accept.step", given: "{\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"validate\"}", wire: "{\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"validate\"}",
{name: "a validate step asked by the runner, before the mover's composition", subject: "mesh.seat.mesh-wants.accept.step", given: "{\"asker\":\"mesh-pipeline-runner\",\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"validate\"}", wire: "{\"asker\":\"mesh-pipeline-runner\",\"branch\":\"main\",\"commit\":\"0123456789abcdef0123456789abcdef01234567\",\"fingerprint\":\"fp-0123\",\"module\":\"nats\",\"pipeline\":\"main.3589\",\"revision\":12,\"source\":3589,\"step\":\"validate\"}",
decode: func(b []byte) (any, error) { var v StepAccept; err := json.Unmarshal(b, &v); return v, err }, subjectIs: regexp.MustCompile("^mesh\\.seat\\.mesh-wants\\.accept\\.step$")},
{name: "input asks a composition step's input by digest", subject: "", given: "{\"call\":\"0123456789abcdef0123456789abcdef\",\"digest\":\"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef\"}", wire: "{\"call\":\"0123456789abcdef0123456789abcdef\",\"digest\":\"0123456789abcdef0123456789abcdef0123456789abcdef0123456789abcdef\"}",
decode: func(b []byte) (any, error) { var v InputInput; err := json.Unmarshal(b, &v); return v, err }, subjectIs: nil},
@@ -157,7 +157,8 @@
"commit": "0123456789abcdef0123456789abcdef01234567",
"revision": 12,
"source": 3589,
"fingerprint": "fp-0123"
"fingerprint": "fp-0123",
"asker": "mesh-pipeline-runner"
}
},
{
@@ -172,7 +173,8 @@
"commit": "0123456789abcdef0123456789abcdef01234567",
"revision": 12,
"source": 3589,
"fingerprint": "fp-0123"
"fingerprint": "fp-0123",
"asker": "mesh-pipeline-runner"
}
},
{
@@ -1362,6 +1362,10 @@
"type": "string",
"description": "the module's build-input fingerprint at the commit"
},
"asker": {
"type": "string",
"description": "the seat name of the part asking the step, mesh-pipeline-runner for the runner; the assigner names the step's progress with it (design 47 H-A-88, H-A-41)"
},
"run": {
"type": "string",
"description": "the run on request's id: its composition writes no want (ADR 0666 section 18)"
@@ -466,6 +466,8 @@ export interface StepEnded {
/** a pipeline step of one mover the assigner serves (design 47 H §745, G §22): validate, the manifest validator built from the take-in's heads run over the revision's manifests, before composition, each machine's declaration composed at the change's heads with the composer built from them, both in the build seat's sandbox */
export interface StepRun {
/** the seat name of the part asking the step, mesh-pipeline-runner for the runner; the assigner names the step's progress with it (design 47 H-A-88, H-A-41) */
"asker"?: string;
/** the watched branch, or the branch of a run on request */
"branch": string;
/** for a rerun, the caller the runtime proved */