mirror of
https://github.com/qwibitai/nanoclaw.git
synced 2026-07-06 18:52:03 +08:00
102ce80fda
The active batch's inReplyTo lived in module-level state in current-batch.ts, but the nanoclaw MCP server runs as a separate stdio subprocess from the poll loop, so getCurrentInReplyTo() always read null there. The a2a reply stamp was therefore dead — only the host peer-affinity fallback kept replies routing. Publish the stamp through session_state in outbound.db (both processes already open it): the poll loop writes it at batch start and clears it in the existing finally; the MCP tools read it with an updated_at staleness guard so a stamp left behind by a killed container isn't reused. Delete current-batch.ts and reseed core.test.ts via the DB so it reflects the real process boundary. Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>