fix(agent): unify live model retry budget - #2211
Merged
Merged
Conversation
Collaborator
Author
|
CI follow-up: the first run exposed a real macOS-only zombie-process race in an existing dispatch cancellation guard. kill(pid, 0) reports an unreaped zombie as present, so the guard could incorrectly authorize SIGKILL escalation after TERM. Commit 201ad29 now requires a non-zombie macOS process state before escalation. The formerly failing test passed once through Cargo, 20 additional consecutive direct runs, and the full six-test dispatch::runner module locally. A fresh CI run has been triggered. |
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.
Summary
Type and Areas
Type: regression fix
Areas: Rust core, AI adapters, CLI runtime/tests
Motivation / Impact
Live sessions could terminate immediately for error categories excluded by RoundExecutor string/category checks even though BitFun already had a retry mechanism. At the same time, transport retries could nest with round retries and produce up to 10 x 10 attempts. The live Agent now gives every model error the same single retry budget, improving task completion without unbounded or multiplied requests.
The first CI run also showed that macOS kill(pid, 0) treats an unreaped zombie dispatch leader as present. That could incorrectly authorize SIGKILL escalation after TERM; the guard now requires a non-zombie process state.
Verification
Reviewer Notes
AiProviderError gains an optional retryAfterMs transport hint. It is backward-compatible on the wire and does not affect retry admission. This PR was AI-assisted and is fully tested at the focused unit, adapter-integration, runtime, and CLI end-to-end levels.
Checklist