A held module keeps what it contributes, a have stuck at waiting-yes clears, and the node-engine shows a composition (issue 774) #184

Merged
mesh-tools merged 5 commits from fix/held-keeps-contributions into main 2026-10-30 23:52:53 +00:00
Showing only changes of commit 7bbba2e39e - Show all commits
+6 -1
View File
@@ -1552,7 +1552,12 @@ func (a *Agent) waitsForYes(ctx context.Context, module string, w wantNow, comp
// Composed back to what runs: a have still waiting for a yes for a move since gone says running again, or it waits
// for a yes nobody needs (issue 774, 2026-10-31: four providers stayed waiting-yes once their consumers composed).
if h, ok := a.env.Haves.Read(ctx, module); ok && h.Phase == string(delivery.PhaseWaitingYes) {
a.writeHave(ctx, Have{Module: module, FP: r.FP, Composed: r.Composed, Phase: string(delivery.PhaseRunning), Sealed: h.Sealed})
// Its sealed values only when they are of what runs; else writeHave reads them (sealedOf).
var sealed delivery.Seals
if h.Composed == r.Composed {
sealed = h.Sealed
}
a.writeHave(ctx, Have{Module: module, FP: r.FP, Composed: r.Composed, Phase: string(delivery.PhaseRunning), Sealed: sealed})
}
return false
}