Draw a plan's order per module from the graph and the manifests' change, and read no after: line (issue 977, part B, ADR 0419)
This commit is contained in:
@@ -149,12 +149,12 @@ var ControllerVerbs = []Verb{
|
||||
"paths": "the files it changes, comma-separated, from the repository's root",
|
||||
"module-dirs": "the directories holding a module.json at the head, comma-separated, as the forge says them",
|
||||
"removed": "the files among paths it deletes, comma-separated"}, []string{"repository", "paths"})},
|
||||
{Name: "delivery-order", Description: "A delivery group's order (novox/hq ADR 0239): its members in the order " +
|
||||
"they are delivered, every pair and why — declared, built by, version skew, engine before controller — and " +
|
||||
"the rules each pair won over by precedence (ADR 0249); the cycle, and each contradiction no precedence " +
|
||||
"resolves with how to declare the order, when the pairs contradict each other.",
|
||||
{Name: "delivery-order", Description: "A delivery group's order (novox/hq ADR 0419): its members in the order " +
|
||||
"they are delivered, every pair and why — built by, verb before caller, version skew, engine before " +
|
||||
"controller — read from the module graph and the manifests' change alone; no `after:` line is read. The " +
|
||||
"cycle, with every module and edge of it, is the one refusal.",
|
||||
Input: schema(map[string]string{"members": "the members, as JSON: [{id, repository, base, head, number, paths, " +
|
||||
"module_dirs, module_dirs_said, removed, after}]"}, []string{"members"})},
|
||||
"module_dirs, module_dirs_said, removed}]"}, []string{"members"})},
|
||||
{Name: "delivery-check", Description: "Ask the build seat for a delivery group's composed check (novox/hq ADR " +
|
||||
"0239): every member's head laid over the mesh in turn and judged as one future state. Answers the ask's id; " +
|
||||
"the verdict is said as `checked` with the group's id. With one member and no group, that head is checked " +
|
||||
|
||||
@@ -38,6 +38,9 @@ type Edge struct {
|
||||
From string `json:"from"`
|
||||
To string `json:"to"`
|
||||
Kind string `json:"kind"`
|
||||
// Why is the rule and the fact that drew an edge of a plan's order, in the words the plan shows (novox/hq ADR
|
||||
// 0419 clause 5): "verb before caller: <seat>.<verb>". Empty on the catalogue's own edges, which Kind names.
|
||||
Why string `json:"why,omitempty"`
|
||||
}
|
||||
|
||||
// Dependencies is the catalogue's dependency relation, whole: every module the mesh holds, with
|
||||
|
||||
@@ -42,12 +42,12 @@ func TestDependenciesAreOneRelationWithTheirKinds(t *testing.T) {
|
||||
return false
|
||||
}
|
||||
for _, want := range []Edge{
|
||||
{"shop", "mesh-tools", EdgeStandsOn},
|
||||
{"builder", "mesh-tools", EdgeStandsOn},
|
||||
{"shop-plugin", "shop", EdgeDeclared},
|
||||
{"shop", "builder", EdgeBuiltBy},
|
||||
{"mesh-controller", "builder", EdgeBuiltBy},
|
||||
{"mesh-tools", "builder", EdgeBuiltBy},
|
||||
{From: "shop", To: "mesh-tools", Kind: EdgeStandsOn},
|
||||
{From: "builder", To: "mesh-tools", Kind: EdgeStandsOn},
|
||||
{From: "shop-plugin", To: "shop", Kind: EdgeDeclared},
|
||||
{From: "shop", To: "builder", Kind: EdgeBuiltBy},
|
||||
{From: "mesh-controller", To: "builder", Kind: EdgeBuiltBy},
|
||||
{From: "mesh-tools", To: "builder", Kind: EdgeBuiltBy},
|
||||
} {
|
||||
if !has(want.From, want.To, want.Kind) {
|
||||
t.Errorf("missing %+v in %+v", want, got)
|
||||
|
||||
@@ -292,6 +292,9 @@ type PlanModule struct {
|
||||
FirstAt *time.Time `json:"first_at,omitempty"`
|
||||
Commit string `json:"commit,omitempty"`
|
||||
Why string `json:"why,omitempty"`
|
||||
// Placed is the edge that put the module after another, and the rule that drew it (novox/hq ADR 0419 clause 5):
|
||||
// "after <module> (verb before caller: <seat>.<verb>)". Empty for a module placed first by nothing.
|
||||
Placed string `json:"placed,omitempty"`
|
||||
// Made is what the walk's build of it did (novox/hq ADR 0350 §4): "reused from <check build>", naming the pull
|
||||
// request's head, the trunk commit and the digests, or "built: <why>". Said in `plan-moved` and kept here.
|
||||
Made string `json:"made,omitempty"`
|
||||
|
||||
@@ -224,9 +224,8 @@ type SourceMoved struct {
|
||||
// stands: a directory is a module only when the merge changed its manifest.
|
||||
ModuleDirsSaid bool `json:"module_dirs_said,omitempty"`
|
||||
|
||||
// Number is the pull request's, Title its title and Body its description (novox/hq ADR 0276): a delivery
|
||||
// group's `after:` lines, read when its members are merged into one batch and their order becomes the
|
||||
// walk's, and the words `plans` names a walk by.
|
||||
// Number is the pull request's, Title its title and Body its description (novox/hq ADR 0276): the
|
||||
// pull request's number and words, which `plans` names a walk by (no `after:` line is read, ADR 0419).
|
||||
Number int `json:"number,omitempty"`
|
||||
Title string `json:"title,omitempty"`
|
||||
Body string `json:"body,omitempty"`
|
||||
|
||||
Reference in New Issue
Block a user