fix(core): fail steps with empty provider output after bounded retries - #40511
fix(core): fail steps with empty provider output after bounded retries#40511ServOMorph wants to merge 1 commit into
Conversation
|
The following comment was made by an LLM, it may be inaccurate: Based on my search, I found potential related PRs:
The most notable is #37843 which directly addresses failing on empty provider output — this PR (40511) may be building upon or superseding that approach with the addition of bounded retry behavior. |
Issue for this PR
Closes #37372
Type of change
What does this PR do?
A provider turn that streams a successful step finish but produces no visible text and no tool call (for example a reasoning-only response) was recorded as a successful step (
finish: "stop"), so the session ended cleanly with an empty assistant turn.The publisher now tracks whether any usable output was streamed: non-blank text deltas or a tool call. When a successful stream has neither, the turn is retried up to two times through the existing bounded turn-transition path. If the budget is exhausted, the step is recorded as a terminal failure (
finish: "error") with a clear message instead of a false success.How did you verify your code works?
packages/core(86 tests insession-runner.test.ts, 129 across the runner files) — all green.bun typecheckinpackages/core— clean.Screenshots / recordings
N/A — core change, no UI.
Checklist