seatlist: Start returns at once and reads the seat on a goroutine; Ready says when the first read ended, Status says it is reading (ADR 0636 §1; issue 1966)

Claude-Session: https://claude.ai/code/session_01NcbgfFSnn24M3GcqttoU7i
This commit is contained in:
2026-11-05 14:35:19 +01:00
parent 99e6badabf
commit 2b9cdb5771
4 changed files with 346 additions and 9 deletions
+286
View File
@@ -674,6 +674,30 @@
],
"description": "what this machine's engine reads of a manifest (ADR 0618 §3)"
}
},
{
"name": "seat-list",
"description": "The seat list this engine holds and what it waits for (novox/hq ADR 0636 §7): each seat's source (trunk or bootstrap) and digest, the seats held from the bootstrap alone, the definitions refused, the last error and whether the seat mesh-catalog has answered. Read-only.",
"callers": "the operator and the healers",
"input": {
"type": "object",
"properties": {}
},
"answer": {
"$ref": "#/defs/SeatList"
}
},
{
"name": "seat-list-again",
"description": "Make this engine read the seat list from the seat mesh-catalog now (novox/hq ADR 0636 §7), the recovery of a list unread; it answers what it holds afterwards, and the error when the read failed. A read that changed nothing still ends the engine's wait.",
"callers": "the operator and the healers",
"input": {
"type": "object",
"properties": {}
},
"answer": {
"$ref": "#/defs/SeatList"
}
}
],
"events": [
@@ -1069,6 +1093,109 @@
}
],
"description": "each node's health as its engine reports it"
},
{
"name": "findings",
"template": "state",
"writer": "holder",
"key-forms": [
{
"key": "<key>",
"value": {
"type": "object",
"description": "one thing an observer sees wrong now",
"properties": {
"v": {
"type": "integer",
"description": "layout version, 1"
},
"key": {
"type": "string",
"description": "scope.id.token"
},
"kind": {
"type": "string"
},
"subject": {
"$ref": "#/defs/FindingSubject"
},
"severity": {
"type": "string",
"enum": [
"urgent",
"warning"
]
},
"summary": {
"type": "string",
"description": "one line"
},
"headline": {
"type": "string"
},
"explanation": {
"type": "string"
},
"resolved": {
"type": "string"
},
"needs": {
"type": "string"
},
"actions": {
"type": "array",
"items": {
"$ref": "#/defs/FindingAction"
}
},
"evidence": {
"type": "array",
"description": "newest first, at most 10",
"items": {
"$ref": "#/defs/FindingEvidence"
}
},
"source": {
"type": "string",
"description": "the row, probe or event that saw it"
},
"resolver": {
"type": "string",
"description": "self, operator, agent or healer:<name>"
},
"ref": {
"type": "string",
"description": "the key's last part when it is not the kind"
},
"observer": {
"type": "string",
"description": "the module that wrote it"
},
"run": {
"type": "string",
"description": "what of its own saw it last"
},
"at": {
"type": "string",
"format": "date-time"
}
},
"required": [
"v",
"key",
"kind",
"subject",
"severity",
"summary",
"source",
"observer",
"at"
]
},
"description": "one finding of the observer that wrote it"
}
],
"description": "the findings this node's engine raises about itself, one key per finding, in the layout of the seat mesh-conditions (its findings state): a key written raises the condition of the same key, a key deleted clears it (novox/hq ADR 0564 §2, ADR 0636 §1); today `machine.<node>.seat-list-unread`"
}
],
"defs": {
@@ -1412,6 +1539,165 @@
"said"
],
"description": "the answer of a read-only judgement"
},
"SeatListHeld": {
"type": "object",
"properties": {
"seat": {
"type": "string"
},
"source": {
"type": "string",
"enum": [
"trunk",
"bootstrap"
]
},
"digest": {
"type": "string",
"description": "the digest of the definition held; empty for a bootstrapped one"
}
},
"required": [
"seat",
"source"
]
},
"SeatList": {
"type": "object",
"description": "what an engine holds of the seat list (novox/hq ADR 0636 §7)",
"properties": {
"status": {
"type": "object",
"properties": {
"heard": {
"type": "boolean",
"description": "the seat mesh-catalog has answered"
},
"held": {
"type": "array",
"items": {
"$ref": "#/defs/SeatListHeld"
}
},
"waiting": {
"type": "array",
"items": {
"type": "string"
},
"description": "the seats held from the bootstrap alone"
},
"refused": {
"type": "object",
"additionalProperties": {
"type": "string"
},
"description": "a trunk definition that does not parse, by seat: the one held stands"
},
"last-error": {
"type": "string"
},
"revision": {
"type": "integer"
}
},
"required": [
"heard",
"held"
]
},
"health": {
"type": "string",
"description": "the one line the engine says of it; empty when nothing waits"
},
"error": {
"type": "string",
"description": "why the read failed, for seat-list-again"
}
},
"required": [
"status",
"health"
]
},
"FindingSubject": {
"type": "object",
"description": "what the condition is about",
"properties": {
"scope": {
"type": "string",
"description": "machine, plan, call, build, merge, provider, seat, bus, core, probe, mesh, delivery or module"
},
"id": {
"type": "string",
"description": "its id within the scope"
},
"machine": {
"type": "string",
"description": "the machine it concerns, when there is one"
},
"also": {
"type": "array",
"description": "the other machines it concerns",
"items": {
"type": "string"
}
}
},
"required": [
"scope",
"id"
]
},
"FindingAction": {
"type": "object",
"description": "one answer the operator may give from a notification",
"properties": {
"label": {
"type": "string"
},
"verb": {
"type": "string",
"description": "the seat verb the operator channel calls"
},
"machine": {
"type": "string"
},
"arguments": {
"type": "object",
"additionalProperties": {
"type": "string"
}
},
"level": {
"type": "string",
"enum": [
"acknowledge",
"approve"
]
}
},
"required": [
"label",
"verb"
]
},
"FindingEvidence": {
"type": "object",
"description": "one observation, as it was said",
"properties": {
"at": {
"type": "string",
"format": "date-time"
},
"said": {
"type": "string"
}
},
"required": [
"at",
"said"
]
}
}
}