From 372ef8ff40991644ec2654c61328f31779f4ad21 Mon Sep 17 00:00:00 2001 From: t Date: Mon, 17 Aug 2026 23:35:36 -0600 Subject: Validation-pass fixes; DESIGN.md describes the shipped seam MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit jobs: a child whose wake pipe cannot be armed is refused up front instead of started into a state nothing can wake (the luv-less drain loop survives only for hosts without a loop); a closing child keeps its concurrency slot and its id's exclusivity until the pump actually exits, so teardown can no longer over-admit new children or let two turns share one session file. Resume-metadata reads honor the plain-error contract on a malformed store. workflow: the built-in schema subset validator is the only validator — the jsonschema probe made behavior depend on an undeclared rock (see rockspec: that dependency is deliberately rejected); dead exports and the unreachable half of the structured-output guard are gone, keeping the empty-arguments provider case. DESIGN.md's seam sections now describe the shipped division: binding-level async jobs and tool control, host-level resolve_model/ExtHost/turn events/ component handles, rock-level policy; protocol bodies run to completion on the loop thread and cannot yield, cancellation is scoped to the stream that opened it, and a child's compaction leaves protocol sessions alone. --- subagents/progress.lua | 10 ++++------ 1 file changed, 4 insertions(+), 6 deletions(-) (limited to 'subagents/progress.lua') diff --git a/subagents/progress.lua b/subagents/progress.lua index 274e2a8..087a3c3 100644 --- a/subagents/progress.lua +++ b/subagents/progress.lua @@ -193,12 +193,10 @@ end -- `tool_call_complete` for one of our tools: claim that entry's component so -- the cards the handler is about to raise have somewhere to render. function M.claim(event) - -- The event is host userdata; a host that predates any of these fields - -- answers nil, and one that predates the whole object cannot be indexed. - local ok, name = pcall(function() - return event.tool_name - end) - if not ok or type(name) ~= "string" or name:sub(1, #TOOL_PREFIX) ~= TOOL_PREFIX then + -- The event is host userdata; an unknown field answers nil rather than + -- raising, and activation already refused a host too old to have these. + local name = event.tool_name + if type(name) ~= "string" or name:sub(1, #TOOL_PREFIX) ~= TOOL_PREFIX then return end if type(event.set_component) ~= "function" then -- cgit v1.3