diff --git a/go/catalogue/manifest.go b/go/catalogue/manifest.go index 5d501f99..38c08f1f 100644 --- a/go/catalogue/manifest.go +++ b/go/catalogue/manifest.go @@ -1246,6 +1246,12 @@ type Artifact struct { // release keeps a manifest that names them whole (design 47 G §340, §409); the manifest validator checks their form. Needs []string `json:"needs,omitempty"` + // Calls are the capability words (design 47 G §488, §605) a package's code calls of the tool runner: the delivery plan + // derives, for each module whose build resolved a version of such a package, an ordering edge to the tool runner stating + // those words on each node, so no manifest names the tool runner's module. Said on a package only; the manifest + // validator checks their form. + Calls []string `json:"calls,omitempty"` + // GeneratedFrom marks a package of a contracts module (novox/hq ADR 0608 §5, design 26 *Contracts modules*): the // directory, relative to the module's, of the seat definitions every file of the package is generated from. A // module carrying it holds contracts only and claims no seat, which the judge refuses naming the seat; the build diff --git a/go/catalogue/reader_release_test.go b/go/catalogue/reader_release_test.go index 43cdf359..fccd9ba5 100644 --- a/go/catalogue/reader_release_test.go +++ b/go/catalogue/reader_release_test.go @@ -9,7 +9,8 @@ func TestTheReaderReleaseReadsTheManifestWordsGWrites(t *testing.T) { m, err := decodeForTest([]byte(`{"module":"mesh-watcher","version":"1.4","needs-approval":["restart","node-engine.composition","finding-written"],` + `"consumes":["*.finding-written","mesh-conditions.findings-asked"],` + `"streams":[{"name":"mesh-watcher-findings","events":["finding-written","finding-cleared","findings-stated"],"max-age-days":7,"max-mib":16}],` + - `"build":{"artifacts":[{"name":"program","kind":"bundle","language":"go","needs":["mesh-grants:program","node-tools:runtime"]}]}}`)) + `"build":{"artifacts":[{"name":"program","kind":"bundle","language":"go","needs":["mesh-grants:program","node-tools:runtime"]},` + + `{"name":"go","kind":"package","language":"go","calls":["put-sessions","finding-calls"]}]}}`)) if err != nil { t.Fatalf("a manifest with G's words was refused: %v", err) } @@ -17,7 +18,8 @@ func TestTheReaderReleaseReadsTheManifestWordsGWrites(t *testing.T) { t.Fatalf("a word was set aside: %v (needs-approval %v)", m.UnknownField(), m.NeedsApproval) } if m.Version != "1.4" || m.Consumes[0] != "*.finding-written" || m.Streams[0].Name != "mesh-watcher-findings" || - len(m.Build.Artifacts[0].Needs) != 2 || m.Build.Artifacts[0].Needs[0] != "mesh-grants:program" { + len(m.Build.Artifacts[0].Needs) != 2 || m.Build.Artifacts[0].Needs[0] != "mesh-grants:program" || + len(m.Build.Artifacts[1].Calls) != 2 || m.Build.Artifacts[1].Calls[0] != "put-sessions" { t.Fatalf("read as %+v", m) } } diff --git a/module.json b/module.json index 489f5b32..3aa807ff 100644 --- a/module.json +++ b/module.json @@ -4,8 +4,8 @@ "slug": "sdk", "build": { "artifacts": [ - { "name": "lib", "kind": "package", "language": "typescript" }, - { "name": "go", "kind": "package", "language": "go", "paths": ["go"] } + { "name": "lib", "kind": "package", "language": "typescript", "calls": ["finding-calls"] }, + { "name": "go", "kind": "package", "language": "go", "paths": ["go"], "calls": ["finding-calls", "ledger-upkeep-calls", "put-sessions", "sent-objects-calls"] } ] }, "resources": []