Repository navigation
feat(server): wake the watcher when an unsettled top-level thread fails - #205
nullStack65 wants to merge 3 commits into
Conversation
On release/native-0.1.10 the pre-commit hook fails on eight unused exports and the pre-push check fails on a scenario typecheck error and a stale agent context budget, so no code change can land without bypassing the hooks. Seven unused exports are used only inside their own module and lose their export. The client setThreadDelegationNudge wrapper has no caller and goes; the server command and its MCP tool stay. The upstream ACP refresh scenario imports rpcClient from scenarios/t3.ts, so the fork's identical helper moves there as upstream has it. The MCP tool list budget takes the measured size after the event subscription and delegation nudge tools landed. Model: claude-opus-5-5 Task: CLO-1066 Agent: claude-code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Git exports GIT_DIR to hooks. Under pre-push, the replay workspace fixture inherited it, so its git init, config, add and commit ran against the pushing worktree: it committed "initial" onto the branch being pushed and wrote the test identity into the shared repository config. Unset the inherited repository selectors, as the server's VcsProcess already does for its own git calls. Model: claude-opus-5-5 Task: CLO-1066 Agent: claude-code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
A failed top-level thread with no launching thread, including one a person created, told nobody, so a 15-minute fleet watchdog had to find it. A new thread-failed event starts a watcher turn through the existing model alert delivery path. It fires once per failed run, only for an unsettled, unarchived, top-level thread that is not a delegated or side-chat thread and has no live run. Delivery uses next_turn so an idle watcher wakes, keys on the run so a replay is not a second wake, waits five minutes per thread after a delivered wake, and never wakes the watcher about itself. Lane events keep going to the launching thread. Launch and delegation also refuse a provider that is not ready, has discovered no models or is signed out, before any thread or run is created, using one readiness check shared with placement and capabilities. Model: claude-opus-5-5 Task: CLO-1066 Agent: claude-code Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
|
Important
This repository does not receive automatic reviews because it has fewer than 10 stars.
|
RESULTReviewer notes only, no verdict (t3code #205, CLO-1066 watcher wake on thread failure)CTO took this PR out of the review queue because of known CI regressions. These are notes from a review that was already running and was asked to stop. This is not a gate record and not a merge verdict. It is a bot result (Claude Opus 5.5, read-only, isolated clone), not human approval. Head
The watcher can't wake itself. It is guarded twice: once when the wake is queued ( Tests at the head: the four touched test files passed 209/209. Not verified: a watcher setting that points at a deleted thread; the usage-limit flood as a live run; whether older peers accept |
A failed top-level thread with no launching thread, including one a person created, tells nobody. Today only the 15-minute fleet watchdog finds it. This PR wakes the configured watcher thread (
modelAlertWatcher) when that happens. The watchdog stays as it is.Stacked on #204 (the release-branch hook baseline fix). The first two commits here are #204's. Merge #204 first; this PR's own change is the top commit,
feat(server): wake the watcher when an unsettled top-level thread fails.Change
ThreadEventAlertsadds athread-failedevent, judged when a run ends. It fires only for a thread that:delegatedFrom) or a side chat;The finding keys on the failed run's id, so replaying the same run is not a second wake. It stops holding once the thread's latest run changes.
ModelAlertReactordeliversthread-failedto the watcher through the existing model-alert outbox, asnext_turn, so an idle watcher starts a turn. After a delivered wake it holds further failure wakes for that thread for five minutes. It drops the wake when no watcher is configured or the failed thread is the watcher itself. Lane-ended events keep going to the launching thread. When the launcher is the watcher and the thread failed, only the failure wake is sent, not a duplicate lane event.providerReadinessConstraintsinservedModel.tsis now the one readiness check shared by launch (provider_unavailable), delegation, placement evidence and the capabilities report.requireAdvertisedModelno longer accepts an empty model catalog.docs/operations/watcher-thread.mdand themodelAlertWatchersetting description cover the new event.Checks
--no-verify.check:changed: format, lint, Knip 2/2, GraphQL, typecheck (37 packages), nearby tests (12 files, 331 tests).ThreadEventAlerts,ModelAlertReactor,OrchestratorMcpService, projecthandlers,placementEvidence.next_turndelivery, both local and remote.Not covered by a test: the self-wake drop (the watcher's own failure). It is checked by reading the code only.
Deploy: fleet
Model: claude-opus-5-5
Task: CLO-1066
🤖 Generated with Claude Code