Skip to content

fix(placement): a seat that faulted a reserve ask is not asked again by any mind until the backoff passes — per peer, expiring by time - #4217

Merged
joelteply merged 3 commits into
canaryfrom
fix/a-refused-seat-is-not-asked-again-this-tick
Sep 19, 2026
Merged

joelteply merged 3 commits into
canaryfrom
fix/a-refused-seat-is-not-asked-again-this-tick

Conversation

@joelteply

Copy link
Copy Markdown
Contributor

Measured 2026-09-19 04:26–04:50Z (Cormac's count, confirmed here: 72 asks, 12 per mind):
five M5 minds re-asked the 5090 for a slot every placement tick through a policy
refusal ("forbidden: no policy grants access to persona/placement/reserve" — the
pre-#4215 seat). ~6 asks/min into the seat everyone queues on, each an ACL evaluation
there; and when the seat was silent, a 30 s RESERVE_DEADLINE wait here per mind per
tick, holding the switch. Stay on refusal left no memory, so the next tick asked again.

A faulted ask — refused by policy, not routed, unanswered within the deadline — is a
property of the SEAT, not of the mind that asked. Key the backoff by peer (one row for
all five minds), length MOVE_COOLDOWN_MS (the same hysteresis a move gets), expiring by
time (its own mirror — forbidden move 11). A capacity refusal (granted: false) is the
seat's honest "not this tick" and is not a fault: it re-asks next tick, because the
seat's ledger changes every turn. Probe placement.reserve.backoff names the fault.

Pure ask_backoff_remaining / note_ask_fault over the map, tested; request_reservation
gates on them and the wire ask moved to send_reservation_ask unchanged.

Test plan

  • CI: cargo test -p continuum-core --lib placement_reservation (new: a_seat_that_faulted_an_ask_is_not_asked_again_by_any_mind_until_the_backoff_passes)
  • Live: after deploy, persona/placement/reserve rows from one asker into a refusing seat drop from ~6/min to ≤ 1 per 10 min per seat; placement.reserve.backoff fires once per fault; grants (placement.return.leased) are unaffected.

🤖 Generated with Claude Code

https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo

…by any mind until the backoff passes — the fault is the seat's, keyed per peer, expiring by time

Measured 2026-09-19 04:26–04:50Z (Cormac's count, confirmed here: 72 asks, 12 per mind):
five M5 minds re-asked the 5090 for a slot every placement tick through a policy
refusal ("forbidden: no policy grants access to persona/placement/reserve" — the
pre-#4215 seat). ~6 asks/min into the seat everyone queues on, each an ACL evaluation
there; and when the seat was silent, a 30 s RESERVE_DEADLINE wait here per mind per
tick, holding the switch. `Stay` on refusal left no memory, so the next tick asked again.

A faulted ask — refused by policy, not routed, unanswered within the deadline — is a
property of the SEAT, not of the mind that asked. Key the backoff by peer (one row for
all five minds), length MOVE_COOLDOWN_MS (the same hysteresis a move gets), expiring by
time (its own mirror — forbidden move 11). A capacity refusal (`granted: false`) is the
seat's honest "not this tick" and is not a fault: it re-asks next tick, because the
seat's ledger changes every turn. Probe `placement.reserve.backoff` names the fault.

Pure `ask_backoff_remaining` / `note_ask_fault` over the map, tested; `request_reservation`
gates on them and the wire ask moved to `send_reservation_ask` unchanged.

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply

Copy link
Copy Markdown
Contributor Author

CONDITIONAL — reviewed at exact head 425e91b. The mechanism is right; one thing makes CI red before it is tested.

RIGHT, checked:

  • The fault/capacity split lands where it must: send_reservation_ask maps a command ERROR outcome through into_result() to Err("seat refused the ask: …") — that is the forbidden reply from the 5090 — so a policy refusal is a fault and backs off; a capacity answer is a successful command carrying granted: false and stays Ok, re-asked next tick. Transport and the 30 s deadline are Err too. Exactly the three fault kinds the doc names.
  • Keyed per seat, expiring by time, one row for all minds, a second seat unaffected — the test pins all four, and it bites (drop note_ask_fault and the second assert fails).
  • The backoff Err surfaces through the existing :681 arm as placement.return.refused reason="seat … faulted an ask Ns ago" — distinguishable from a real timeout by text, and placement.reserve.backoff is emitted once per fault. Spill asks share the row, which is intended: the fault is the seat's.
  • Rate after: one ask per seat per MOVE_COOLDOWN_MS instead of one per mind per tick — 72 in the window becomes ~2.

THE CONDITION: two new .unwrap_or_else(|e| e.into_inner()) (the two ASK_BACKOFF.lock() sites) carry no same-line // comment. The unwrap ratchet was pinned to the measured 2264 by #4213 at 03:35Z with zero slack, so cargo test --lib goes red here at 2266 — that is the guard doing what it was pinned to do, on the branch, before the merge. Write the reason on each line (a poisoned dedupe map is not truth; into_inner takes the last state — the same reason SAID.lock() in serving_daemon carries) and it is APPROVE on green.

@joelteply
joelteply enabled auto-merge (squash) September 19, 2026 04:58
@joelteply
joelteply disabled auto-merge September 19, 2026 05:38
…td MutexGuard in scope across the wire await made request_reservation's future !Send (CI on #4217)

Co-Authored-By: Claude Fable 5.1 <[email protected]>
Claude-Session: https://claude.ai/code/session_01LoTjvf5j3Ez13g6k8mRkFo
@joelteply
joelteply enabled auto-merge (squash) September 19, 2026 05:55
@joelteply
joelteply merged commit 5418625 into canary Sep 19, 2026
6 checks passed
@joelteply
joelteply deleted the fix/a-refused-seat-is-not-asked-again-this-tick branch September 19, 2026 06:01
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant