Repository navigation
docs(rfd): add error classification RFD - #2755
Open
slapoguzov wants to merge 1 commit into
Open
slapoguzov wants to merge 1 commit into
slapoguzov wants to merge 1 commit into
Conversation
Proposes optional `kind`, `retryable`, and `retryAfterMs` fields in the `data` object of JSON-RPC errors, so Clients can tell rate limits, usage limits, context overflow, and other failures apart without parsing the message. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Preview approval requiredThis pull request comes from a fork, so Mintlify won't build a preview until someone with write access approves commit |
This branch has not been deployed
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.
Adds a draft RFD for classifying errors that end a prompt turn.
Today a Client gets a JSON-RPC code and a message, and most failures use
-32603. It cannot tell a rate limit from an exhausted usage plan or a context window overflow, so it cannot decide whether to offer a retry. Agents already know the cause: the Claude Agent SDK and the Codex app-server both report typed errors, but ACP has no place for them.The RFD adds three optional fields to the
dataobject of the existing JSON-RPC error:kind: an open enum such asrate_limited,usage_limit,context_window_exceeded,overloaded, orinvalid_request. Custom values start with_.retryable: whether the same request, sent again without changes, may succeed. Absent means unknown.retryAfterMs: the minimum delay before trying again, when the provider gives one.The fields work the same way in a failed
session/promptresponse and in theerrorof an idlestate_updatewithstopReason: "error", which fills the gap the v2 prompt lifecycle RFD left for "finer categories ... indata". Authentication keeps-32000. No new error codes or capabilities are added.The RFD includes a mapping from current Claude and Codex errors to the proposed kinds.
🤖 Generated with Claude Code