Repository navigation
fix(loop): harden CLI surface — drop session-policy + ghost flags, per-flag help, dead-worker sweep on run exit - #487
Merged
Conversation
…r-flag help, dead-worker sweep on run exit - run: remove --session-policy (fresh is the default; resume only via an explicit --resume-session <id> pin — the goal-level retention is a single field, so an implicit resume would hand one worker's session to another under parallel workers) - delete ghost flags the reject array accepted but parse never read: supervisor propose (--outcome/--receipt-id/--adapter-id/--authority-ref/ --host-capabilities), supervisor receipt (--agent-id/--kind/--summary/ --target-agent-id/--capabilities), supervisor events (all but --goal), replan ack (--format/--json), replan obligations (--delta-kind), scheduler tick (--cadence-class) - scheduler tick --progression now warns it is bootstrap-only instead of silently ignoring it once state exists - render per-flag help (<command> --help / <command> <sub> --help) with defaults + constraints sourced from each handler; agent gains subcommand registrations so agent onboard|list|contract|recipe|succession|collective --help resolve - run exit now sweeps dead-holder leases (notify_dead_holders) so a crashed worker surfaces to the supervisor without a scheduler-tick cron
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Loop CLI surface hardening, five changes that all close the gap between what the CLI claims and what it does:
1. Remove
--session-policy(run)Fresh is now the default; resume only via an explicit
--resume-session <id>pin. The goal-levelsession_retentionis a single field (whichever run wrote back last), so an implicit "resume the retained session" would hand one worker's session to another under parallel workers.2. Delete ghost flags
Flags the
reject_unknown_flagsarray accepted but the parse closure never read (silent no-ops):supervisor propose:--outcome --receipt-id --adapter-id --authority-ref --host-capabilitiessupervisor receipt:--agent-id --kind --summary --target-agent-id --capabilitiessupervisor events: all but--goalreplan ack:--format --jsonreplan obligations:--delta-kindscheduler tick:--cadence-class3. Per-flag help
<command> --help/<command> <sub> --helpnow render each flag with its default + constraints, sourced from each handler.agentgains subcommand registrations soagent onboard|list|contract|recipe|succession|collective --helpresolve.4.
scheduler tick --progressionwarnsIt is bootstrap-only; once state exists it now warns instead of silently ignoring the flag.
5. Dead-worker sweep on run exit
runnow sweeps dead-holder leases (notify_dead_holders) on exit, so a SIGKILL'd/crashed worker surfaces to the supervisor without a scheduler-tick cron.Verification
cargo fmt -p future-loop --check✅cargo clippy -p future-loop --all-targets✅ (no warnings)cargo test -p future-loop --lib(392 passed) + integration suites (console_drive_a/b/c/cov100/g12,scheduler_drive/state_contract,run_lifecycle/identity,agent_run_drive/agent_client_executor,cli_registry_contract) ✅Companion skills bump: future-skills #41 (v3.11.0).