From bdb4edd82096ce21f4881305ccf8adaa42615197 Mon Sep 17 00:00:00 2001 From: jochen Date: Sat, 21 Nov 2026 11:48:04 +0100 Subject: [PATCH] Design 47 H1: the indexer's retired call-unanswered names scope call MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The tool runner's approval findings of call-unanswered are of scope machine; the indexer's entry now names scope call, so no approval key is cleared even where an id form would match. The test's negative ids take the approval form. Builds: design 47 H H-A-249, G ยง580 --- .../internal/index/finding_kinds_test.go | 9 +++++---- modules/mesh-delivery-indexer/internal/index/findings.go | 4 ++-- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/modules/mesh-delivery-indexer/internal/index/finding_kinds_test.go b/modules/mesh-delivery-indexer/internal/index/finding_kinds_test.go index fe735baf..070fc772 100644 --- a/modules/mesh-delivery-indexer/internal/index/finding_kinds_test.go +++ b/modules/mesh-delivery-indexer/internal/index/finding_kinds_test.go @@ -184,9 +184,9 @@ func TestFindingKindsHoldEveryKindTheCodeRaises(t *testing.T) { } } // H-A-249: the retired call-unanswered names the ids the indexer's unanswered calls are written under, as in a key - covers := func(id string) bool { + covers := func(scope, id string) bool { for _, r := range RetiredFindingKinds { - if r.Kind == mcc.KindCallUnanswered && (slices.Contains(r.IDs, id) || + if r.Kind == mcc.KindCallUnanswered && (r.Scope == "" || r.Scope == scope) && (slices.Contains(r.IDs, id) || slices.ContainsFunc(r.Prefixes, func(p string) bool { return strings.HasPrefix(id, p) })) { return true } @@ -195,11 +195,12 @@ func TestFindingKindsHoldEveryKindTheCodeRaises(t *testing.T) { } for _, id := range []string{keyID("node-build-go." + StepsVerb), keyID("node-build-image." + StepsVerb), keyID(floorKey("mesh-tools")), keyID(BuilderVersionsCall)} { - if !covers(id) { + if !covers(mcc.ScopeCall, id) { t.Errorf("the retired call-unanswered does not cover the indexer's id %s", id) } } - if covers("mesh-hand-acts.warranted") || covers("ask-1") { + // the approval gate's findings: scope machine, id =2e + if covers("machine", "novox=2eask-1") || covers("machine", "node-build-go.steps") || covers(mcc.ScopeCall, "novox=2eask-1") { t.Error("the retired call-unanswered covers an id of the tool runner's") } } diff --git a/modules/mesh-delivery-indexer/internal/index/findings.go b/modules/mesh-delivery-indexer/internal/index/findings.go index faa1fac9..542c707b 100644 --- a/modules/mesh-delivery-indexer/internal/index/findings.go +++ b/modules/mesh-delivery-indexer/internal/index/findings.go @@ -28,10 +28,10 @@ var FindingKinds = []string{PinMissingKind, OutOfStepKind, PackagesNotPublishedK // RetiredFindingKinds are kinds no code of the indexer raises any more, which its writer clears once at its start (H-A-247 // (3)): merge-untaken went with H-A-82; call-unanswered became indexer-call-unanswered (H-A-247 (2)), and since the tool -// runner's writer owns call-unanswered in the same state, only the ids the indexer wrote under it are cleared (H-A-249): +// runner's writer owns call-unanswered in the same state, only the ids the indexer wrote under it, in scope call, are cleared (H-A-249): // the seed's .steps (every build seat is named node-build-), the floor's mesh-catalog.versions-floor. // and the versions fill's mesh-delivery-builder.builder_versions. -var RetiredFindingKinds = []views.RetiredKind{{Kind: "merge-untaken"}, {Kind: mcc.KindCallUnanswered, +var RetiredFindingKinds = []views.RetiredKind{{Kind: "merge-untaken"}, {Kind: mcc.KindCallUnanswered, Scope: mcc.ScopeCall, IDs: []string{keyID(BuilderVersionsCall)}, Prefixes: []string{"node-build-", keyID(FloorCall) + "."}}} // FindingWriter is the indexer's finding writer, mesh-sdk's held writer of the seat mesh-conditions' generated finding (design