You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
fix(errors): max_turns stays "Exceeded max turns" — observe the repeated failure, don't diagnose it
Reviewer concern on the ABCA-662 work: re-titling a max_turns failure as "Ran out
of turns retrying a failing step" over-claims. The stuck-guard's trailing window is
only the last ~6 tool calls, which genuinely CANNOT distinguish a hard blocker (bad
creds, no permission — more turns won't help) from a long task that made real
progress and hit a recoverable snag only at the tail (more turns / a retry WOULD
help — 662 itself: siblings pushed fine with the same token). Framing the whole run
around its last 6 calls misrepresents the latter.
- error-classifier: drop the separate "retrying a failing step" bucket. A max_turns
failure stays the plain "Exceeded max turns"; the description/remedy point the
reader at the observed detail and still surface the environment-blocker path,
but assert NO cause.
- stuck_guard.recent_failure_summary: emit a NEUTRAL observation ("last tool calls
repeated: `<cmd>` → <err>") instead of "spinning on failing tool calls". The
mid-run steer TO the agent (an advisory nudge, not a user surface) still says
"spinning" — that's fine, it's coaching the agent, not classifying the outcome.
- tests updated to pin the neutral wording + assert the title is NOT re-framed.
title: 'Ran out of turns retrying a failing step',
325
-
description: 'The agent hit its max-turns limit while the last several tool calls were the same repeated failure (see the detail below). That means one of two things — the failing step is a hard blocker no extra turns can fix, OR the task was long and hit a recoverable snag near the end and simply ran out of turns.',
326
-
remedy: 'Check the failing operation in the detail below. If it is an environment/tooling blocker (auth, credentials, permission, network, disk), retrying more won\'t help — fix the environment (an admin), then reply here to retry. If it looks transient or recoverable (a flaky/temporary error, or a sibling task with a shorter to-do got past the same thing), just reply to retry and/or raise --max-turns.',
327
-
retryable: true,
328
-
errorClass: ErrorClass.USER,
329
-
},
330
-
},
331
-
{
309
+
// A max-turns cap is a correct, self-explanatory classification. When the
310
+
// stuck-guard observed the last several tool calls repeating the SAME failure
311
+
// it is appended to the reason as a neutral OBSERVATION ("last tool calls
312
+
// repeated: `<cmd>` → <err>") — we surface WHAT was on screen but deliberately
313
+
// make NO causal claim about whether more turns would have helped: the
314
+
// trailing window (last 6 calls) can't distinguish a hard blocker from a long
315
+
// task that hit a recoverable snag only at the tail, so re-framing the whole
316
+
// run as "retrying a failing step" would misrepresent the latter. The reader
317
+
// sees the observed detail and the neutral remedy and decides.
description: 'The agent reached the configured ``max_turns`` limit before completing.',
337
-
remedy: 'Raise ``--max-turns`` on the submit call, simplify the task, or break it into smaller sub-tasks.',
322
+
description: 'The agent reached the configured ``max_turns`` limit before completing. If a repeated tool failure was observed near the end, it is shown in the detail below.',
323
+
remedy: 'Look at the detail below to see what the agent was doing when it ran out. Raise ``--max-turns`` on the submit call, simplify the task, or break it into smaller sub-tasks — and if the detail shows an environment/tooling blocker (auth, credentials, permission, network, disk), fix that first, then reply here to retry.',
0 commit comments