pub struct ExecError {
pub status: u16,
pub scope: FailureScope,
pub body: Bytes,
pub headers: Box<HeaderMap>,
pub retry_after: Option<Duration>,
pub direct: bool,
pub addon: Option<Box<HeaderMap>>,
}Fields§
§status: u16§scope: FailureScope§body: BytesUpstream error body (bounded), or a message for locally generated errors.
headers: Box<HeaderMap>Upstream response headers, for the scheduler and passthrough policy. The server never emits these by default. Boxed: errors are the cold path.
retry_after: Option<Duration>Scheduler hint parsed from upstream. Not permission to send Retry-After downstream.
direct: boolSend status, body and filtered headers to the client unchanged instead of the route’s normal error shape (claude_executor_fast_error.go).
addon: Option<Box<HeaderMap>>Headers this error hands the client under requests.passthrough-headers (Go
ErrorMessage.Addon, filled only from errors with Headers(): Codex and xAI
WebSocket error frames and stream bootstrap failures). headers stays the
classification copy and is never sent, except as a direct response’s headers.
Implementations§
Source§impl ExecError
impl ExecError
Sourcepub const REPLAY_REQUIRED: &'static str = r#"{"error":{"message":"upstream transport requires full HTTP replay","type":"server_error","code":"upstream_http_replay_required","status":426}}"#
pub const REPLAY_REQUIRED: &'static str = r#"{"error":{"message":"upstream transport requires full HTTP replay","type":"server_error","code":"upstream_http_replay_required","status":426}}"#
Body of the replay signal (Go UpstreamWebsocketReplayRequiredError).
Sourcepub fn replay_required() -> Self
pub fn replay_required() -> Self
A continuation turn lost its upstream socket: the client must resend the full conversation. Request-scoped: no credential is at fault.
pub fn is_replay_required(&self) -> bool
Trait Implementations§
Source§impl Error for ExecError
impl Error for ExecError
1.30.0 · Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
use the Display impl or to_string()