Repository navigation
Consolidation: goal recovery handoffs, trigger agents made like --new, test races - #476
Conversation
…policy, test races - Goals (#355): a turn that completes while its goal's check runs is held and checked once that check settles, unless the agent goes on in a newer turn, as a work queue processes an item re-added during processing again. After a restart that replays two finished goal turns, the second is no longer dropped. A replayed continuation whose prompt changed (idempotency_conflict) counts as going on, not as a failure. - Goals (#355): every ending is noted in STORE.lookout/goals/ended/BOT.json (was met/, success only) before the goal file goes, so a lookout that restarts before the lead heard still tells how the goal ended. - Triggers (#404): `--start` agents are made through the same `made()` as `sonny --new`: auto gate, workspace-write sandbox, fallback. Agents an older trigger made with no sandbox and no gate are confined at their next fire. - Sonny reconcile reads every page of a project's bots (#150). - Tests: node scripts get 60 s under test (#418); test_served's /proc wait tolerates the process going between looks; the soak names why its events connection closed and keeps the daemon's stderr. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA
Codex Review SummaryThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: 6d3dbe8ad5
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…ts never drop Codex review on #476: an idempotency_conflict names the turn the request started, so it counts as the turn the agent goes on in, and the newer-turn rule holds with changed check output. The settlement channel is unbounded, holding a few per agent with a goal at most, since a goal's turn waits on its one settlement and a full channel dropped it. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA
There was a problem hiding this comment.
💡 Codex Review
Here are some automated review suggestions for this pull request.
Reviewed commit: d0e662774f
ℹ️ About Codex in GitHub
Your team has set up Codex to review pull requests in this repo. Reviews are triggered when you
- Open a pull request for review
- Mark a draft as ready
- Comment "@codex review".
If Codex has suggestions, it will comment; otherwise it will react with 👍.
Codex can also answer questions or update the PR. Try commenting "@codex address that feedback".
…counts idle turns from before the check it reruns Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA
|
The Generated by Claude Code |
…urn (#497) * Consolidation from the external review: goal recovery, trigger agent policy, test races - Goals (#355): a turn that completes while its goal's check runs is held and checked once that check settles, unless the agent goes on in a newer turn, as a work queue processes an item re-added during processing again. After a restart that replays two finished goal turns, the second is no longer dropped. A replayed continuation whose prompt changed (idempotency_conflict) counts as going on, not as a failure. - Goals (#355): every ending is noted in STORE.lookout/goals/ended/BOT.json (was met/, success only) before the goal file goes, so a lookout that restarts before the lead heard still tells how the goal ended. - Triggers (#404): `--start` agents are made through the same `made()` as `sonny --new`: auto gate, workspace-write sandbox, fallback. Agents an older trigger made with no sandbox and no gate are confined at their next fire. - Sonny reconcile reads every page of a project's bots (#150). - Tests: node scripts get 60 s under test (#418); test_served's /proc wait tolerates the process going between looks; the soak names why its events connection closed and keeps the daemon's stderr. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA * Goals: a changed continuation is the turn the daemon names; settlements never drop Codex review on #476: an idempotency_conflict names the turn the request started, so it counts as the turn the agent goes on in, and the newer-turn rule holds with changed check output. The settlement channel is unbounded, holding a few per agent with a goal at most, since a goal's turn waits on its one settlement and a full channel dropped it. Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA * Goals: a deferred check holds its turn from when it starts; a replay counts idle turns from before the check it reruns Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA * Sonny: date the person's words by when each was written, not by its turn Co-Authored-By: Claude Opus 5.5 <[email protected]> Claude-Session: https://claude.ai/code/session_013jkdGHQFvDYzqCcbhWmojA --------- Co-authored-by: Claude <[email protected]>
Part of the consolidation cycle from an external review of main at 52c844a. I re-checked each finding against 5f2c126. #422 was already fixed by #442. This PR fixes what was still true in goals, triggers and tests. MCP host bounds and ACP identity (#347, #335, #332) are in a parallel thread, and #317 is in the person-label PR.
Goals: accepted work ends visibly (#355)
idempotency_conflict) means the agent already went on. It is no longer told as "could not go on".STORE.lookout/goals/ended/BOT.jsonbefore the goal file goes, like a Job's terminal condition. This replacesmet/, which recorded success only. A lookout that restarts before the lead heard reads the outcome from there, so the lead still hears that the goal gave up or ran out of budget. The roster'scheckedreadsmetfrom the same note.The sandboxed-check part of #355 needs a daemon op, so it stays open for discussion.
Trigger
--startagents get the same policy as--new(#404)sonny --newand a trigger's--startnow make agents through onemade(): Sonny's tools, anautogate, theworkspace-writesandbox, the person's fallback, cache lifetime and hide_senders. There's one way in, so an agent nobody opens never has more reach than one they do. A doubted call waits in/approvals, as any agent's does.fullnames its sandbox, so it stays as it is.--ifgate runs as the trigger, outside the agent, and the folder is its workspace.Also
reconcilereads every page of a project's bots. Before, it read the first 256 only (Sonny: declined review findings (attach and reconnect races) #150).cfg(test), where node's cold start on a busy runner can take the UI's 5 s by itself.test_served: the/proc/PID/statwait no longer crashes when the process goes between the existence check and the read (seen on main, run 41000300075).daemon.stderr) or let the connection go (with the last event). The failure in run 40991624096 had no diagnostics.Tests
test_two_goal_turns_that_ended_while_the_lookout_was_down_are_both_checkedandtest_how_a_goal_ended_reaches_the_lead_after_a_restart.--starttest now checks the auto gate and the sandbox. There's a unit test for which agents get confined at their next fire.cargo test -p sonny(613 passed), clippy and fmt, andtests.test_served,tests.test_triggerandtests.test_soakwith bubblewrap (51 OK).