From 573c16596f033a815c8446f9d46b0ad6b75a31e8 Mon Sep 17 00:00:00 2001 From: Guillermo Montero Date: Thu, 17 Sep 2026 17:39:49 +0200 Subject: [PATCH] docs(policy): document safe range for dev_stall_nudges_cap --- src/bmad_loop/policy.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/bmad_loop/policy.py b/src/bmad_loop/policy.py index 319af2467..d544c6a5f 100644 --- a/src/bmad_loop/policy.py +++ b/src/bmad_loop/policy.py @@ -135,7 +135,9 @@ class LimitsPolicy: # the refill until session_timeout_min, burning a turn per cycle (#149). # After this many total nudges the session is declared stalled instead # (post-kill reconcile still rescues a finished one whose artifact is on - # disk). 0 = stall on first grace expiry. + # disk). 0 = stall on first grace expiry. Safe range: keep this + # comfortably below session_timeout_min / (dev_stall_grace_s / 60), so + # the cap fires before the session timeout ceiling would anyway. dev_stall_nudges_cap: int = 6 # same monotonic cap for injected plugin-workflow sessions: one that keeps # ending its turn without writing its completion marker is declared stalled