From 0aff33d617e4b5b48f6e7a1f68256ea972674803 Mon Sep 17 00:00:00 2001 From: jochen Date: Sun, 22 Nov 2026 00:36:33 +0100 Subject: [PATCH] Claim composition-diff among the node-engine seat's verbs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The group's node-engine seat defines composition-diff, and the engine has answered it since E5, but its claim did not name it, so the manifest validator refused the manifest: the seat's protocol promises a verb the claim does not serve. The claim serves it, and the manifest test holds the claim to every verb of the seat's contract. Builds: design 47 H2 §813 (3); H-A-349 DQ-12b, H-A-355 (2), H-A-392; mesh-contracts feat/47-H2 3fbe3361 (the seat's composition-diff) --- module.json | 1 + packaging/operator_keys_test.go | 21 +++++++++++++++++++++ 2 files changed, 22 insertions(+) diff --git a/module.json b/module.json index 088d8463..c0ba5c01 100644 --- a/module.json +++ b/module.json @@ -29,6 +29,7 @@ "acts", "packages", "composition", + "composition-diff", "compose", "compose-candidate", "manifest-reads", diff --git a/packaging/operator_keys_test.go b/packaging/operator_keys_test.go index 27970245..6798db6c 100644 --- a/packaging/operator_keys_test.go +++ b/packaging/operator_keys_test.go @@ -8,6 +8,7 @@ import ( "strings" "testing" + "git.novox.be/novox/mesh-contracts/go/seats/nodeengine" "git.novox.be/novox/mesh-sdk/go/catalogue" "git.novox.be/novox/mesh-sdk/go/declaration" ) @@ -126,6 +127,26 @@ func testTheManifestConsumesTheBackupEvent(t *testing.T) { } // Design 47 H2 §813 (12), H-A-388: it states the declaration Version it reads, the one its contract parses, so the // delivery plan orders the composer that writes that Version after it. + // The claim of node-engine serves every verb the seat's contract defines, composition-diff among them (the H2 K row of + // mesh-contracts, H-A-355 (2), H-A-392): a claim short of one is refused by the manifest validator. + if parsed, err := catalogue.Decode(raw); err == nil { + var serves []string + for _, c := range parsed.Claims { + if c.Name == nodeengine.Seat { + serves = c.Serves + } + } + for _, verb := range []string{nodeengine.VerbHandOver, nodeengine.VerbAccessAct, nodeengine.VerbJudgeDirectories, + nodeengine.VerbSetuidSearch, nodeengine.VerbRootFree, nodeengine.VerbActs, nodeengine.VerbPackages, + nodeengine.VerbComposition, nodeengine.VerbCompositionDiff, nodeengine.VerbCompose, nodeengine.VerbComposeCandidate, + nodeengine.VerbManifestReads, nodeengine.VerbApplyOrder, nodeengine.VerbSeatList, nodeengine.VerbSeatListAgain, + nodeengine.VerbFirstViews, nodeengine.VerbFirstViewAgain, nodeengine.VerbEntryAgain, nodeengine.VerbProcessBuilds, + nodeengine.VerbConverged} { + if !slices.Contains(serves, verb) { + t.Errorf("the claim of %s does not serve %s: %v", nodeengine.Seat, verb, serves) + } + } + } // H-A-394 (1): a module that claims a seat is core. if parsed, err := catalogue.Decode(raw); err != nil || parsed.Class != catalogue.ClassCore { t.Errorf("the manifest's class is %q, and the node-engine claims a seat (%v)", parsed.Class, err)