Node-engine: a held own composition that was handed stays handed, as a held module's does (ADR 0636 §1; issue 1966)

Claude-Session: https://claude.ai/code/session_01NcbgfFSnn24M3GcqttoU7i
This commit is contained in:
2026-11-05 16:28:02 +01:00
parent b0baa17836
commit e282e08917
2 changed files with 66 additions and 2 deletions
+5 -2
View File
@@ -1029,8 +1029,11 @@ func (c *Composer) compose(ctx context.Context) []agent.Update {
out = append(out, agent.Update{Key: key, Value: raw, Revision: c.rev})
}
for key := range c.handed {
if _, module, _, _, err := engcomp.ParseKey(key); err == nil && module != "" {
if _, isHeld := held[module]; isHeld {
if _, module, _, isNode, err := engcomp.ParseKey(key); err == nil {
if isNode {
module = agent.NodeModule // the node's own composition is held under its scope
}
if _, isHeld := held[module]; isHeld && module != "" {
continue // held: what was handed of it stays, so the node keeps running it
}
}