sanad: coder panel P0 — guards + runner base - #1
Merged
Merged
Conversation
_trip_budget is now idempotent per turn (TurnState.budget_tripped), so multiple StepBegins past max_steps_per_turn journal the breach exactly once instead of once per offending step. Tracks the trip task reference (self._trip_task) and cancels/clears it on the same teardown paths as the wall-clock watchdog.
…urns, deny-by-default
This was referenced Aug 13, 2026
This was referenced Aug 20, 2026
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.
What
P0 of the coder agent panel (spec, plan): the platform guards and generalized runner base that every later phase builds on.
WireRunnerbase extracted fromArchitectRunner(byte-compatible — architect routes and tests untouched); parametrized handshake capabilities +on_requesthook (base = reject, deny-by-default)turn_budget_exceededthen cancel; architect stays unlimitedCoderRunner: one per conversation,sanad --wire --session <id>, budgets mandatory, per-conversation registry wired into the idle probe/internal/coderroutes (P0 subset): create/open/send/turn/follow/cancel/stop; NDJSON turn streaming; flag-gated byCODER_ENABLED(404 fail-closed); ticket redemption +fixed_userparity with the architect; malformed-cid guardSANAD_CODER_PANEL_EMAILS, fail-closed, separate from the terminal gateSecurity posture (P0)
Most-restrictive by construction: capabilities
false/false, every inbound approval/question request rejected with -32601 (golden-tested at runner and HTTP level), no respond endpoint exists. The approvals bridge is P1, gated behind the trust-store hardening.Tests