Gate and keeper, review round 1: a group's end is told by its whole event, the gate pinned at mesh-delivery 7b7096f3, the keeper's row dropped (issue 1585, ADR 0633)
mesh/delivery-group group feat/take-in rejected: composed together: the checker's verdict at the members' heads (38623984d6ad): mesh-build-go
mesh/delivery closed: a newer head of the same pull request
mesh/check failed (2): mesh-build-go: the indexer's judge at the group's mesh-delivery head 7b7096f37ea76e1…; and 1 more | d023a25849f3 on fd4931a75261

The gate passes by a group's end only when the event is the forge bridge's forge.group.merged whole, so the merged message
of a repository named forge/group is read as one; row in the holder test. The keeper's take-in-waits row (T26) is dropped:
it showed nothing the keeper does not already hold. The gate pins forgemsg at mesh-delivery 7b7096f3.

Claude-Session: https://claude.ai/code/session_01JG73KG7AfSdh6FP8VrBqCn
This commit is contained in:
2026-11-05 00:29:37 +01:00
parent ebe1248f0b
commit d023a25849
5 changed files with 13 additions and 18 deletions
@@ -240,14 +240,6 @@ func TestTheKeeperCarriesNoControllerConditionAndClearsWhatItCarriedOnce(t *test
if err := r.k.Finding(watchman, key, raw, false); err != nil {
t.Fatal(err)
}
// take-in-waits (issue 1585) is an observer's kind with no row in Homes: its finding is raised and EndCarried leaves it (T26).
takeKey, takeRaw := finding(t, watchman, health.ScopeMachine, "g14", "take-in-waits", "take-in", health.Warning, r.now)
if err := r.k.Finding(watchman, takeKey, takeRaw, false); err != nil {
t.Fatal(err)
}
if _, open := r.open(takeKey); !open {
t.Fatal("a take-in-waits finding raised no condition")
}
r.said = nil
// Carried while the controller ran: two of kinds that ended with it, still open in conditions.
for _, c := range []health.Condition{
@@ -265,9 +257,6 @@ func TestTheKeeperCarriesNoControllerConditionAndClearsWhatItCarriedOnce(t *test
if _, open := r.open(key); !open {
t.Error("a condition a finding holds was cleared")
}
if _, open := r.open(takeKey); !open {
t.Error("EndCarried cleared a take-in-waits condition")
}
if n, err := r.k.EndCarried(); err != nil || n != 0 || r.changes() != "" {
t.Errorf("a second EndCarried cleared %d (%v)", n, err)
}
@@ -256,6 +256,12 @@ func TestAMergedGroupEndsMergedWithSourceMainMoved(t *testing.T) {
if len(w.h.refusals) != 0 {
t.Errorf("the gate refused a group's end: %v", w.h.refusals)
}
// The repository forge/group's merged message ends the same way: it is decoded as a forge message, and this one,
// which is none, is refused.
w.h.Forged("mesh-delivery-forge-bridge.forge.forge.group.merged", []byte(`{"v":1,"group":"feat/y"}`))
if len(w.h.refusals) != 1 {
t.Errorf("forge/group's merged message was passed by as a group's end: refusals %v", w.h.refusals)
}
}
// ADR 0419 §2, issue 978: a description's `after:` line is not read, and says so once on its pull request. The
@@ -313,16 +313,16 @@ func (h *Holder) mergeValue(name, key string, approved map[string]string, target
return m, len(m.Pulls) > 0 && state == sdk.MergeMerged
}
// forgeGroupEnd ends the subject of a group end on FORGE, the forge bridge's event name: the four-part form of a pull
// request's message has no such tail.
const forgeGroupEnd = "." + forgemsg.ForgeGroupEndEvent
// forgeGroupEnd is the whole event of a group's end on FORGE, the forge bridge's event name under its module: compared
// exactly, so the merged message of a repository named forge/group, which ends the same way, is read as one.
const forgeGroupEnd = sdk.ForgeBridgeModule + "." + forgemsg.ForgeGroupEndEvent
// Forged takes a message of the forge bridge on FORGE: the gate follows a merge and the refusal of a merge, and nothing else.
//
// The end of a group's merges (`forge.group.merged`, a body this gate has no use for: the gate wrote the merges itself) is
// the indexer's, and is ignored before it is decoded, so no refusal is said for it (issue 1585, ADR 0633 clause 4).
func (h *Holder) Forged(event string, body []byte) {
if strings.HasSuffix(event, forgeGroupEnd) {
if event == forgeGroupEnd {
return
}
f, err := forgemsg.DecodeForge(body)
+1 -1
View File
@@ -3,7 +3,7 @@ module mesh-delivery-gate
go 1.26.0
require (
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104230501-4e4601a1eb90
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104232856-7b7096f37ea7
git.novox.be/novox/mesh-sdk/go v0.1.14-0.20261104002338-5a38a1221659
github.com/nats-io/nats-server/v2 v2.11.17
github.com/nats-io/nats.go v1.54.0
+2 -2
View File
@@ -1,5 +1,5 @@
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104230501-4e4601a1eb90 h1:8akSVoPjgngMbC1JIstcUzfKyYs13gDaboDRKC4NQ/A=
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104230501-4e4601a1eb90/go.mod h1:Xxg9VI4y755tznAS2PygQFe2V3/aIzjRn3/06+Br9nQ=
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104232856-7b7096f37ea7 h1:VWgmpV8KOOjq+KFqq0ofyZ52HUHoBfCqP5Z0/vUq++k=
git.novox.be/novox/mesh-delivery/modules/mesh-delivery-forge-bridge/forgemsg v0.0.0-20261104232856-7b7096f37ea7/go.mod h1:Xxg9VI4y755tznAS2PygQFe2V3/aIzjRn3/06+Br9nQ=
git.novox.be/novox/mesh-sdk/go v0.1.14-0.20261104002338-5a38a1221659 h1:tK7MzxVm/ECNg1Yblhh1ynVEthbZCg2mSPW0wQZC0b0=
git.novox.be/novox/mesh-sdk/go v0.1.14-0.20261104002338-5a38a1221659/go.mod h1:ouERNpZizzwZ0HLEtAypsY9FR20FyUgUYRni6J7kVCY=
github.com/antithesishq/antithesis-sdk-go v0.7.0-default-no-op h1:Z/MZK75wC/NSrkgqeNIa7jexam9uWzhLmFTSCPI/kn0=