pub enum NativeHarnessError {
Failed(String),
Encode(String),
ChannelClosed,
ModelRateLimit(String),
ModelAuth(String),
ModelContextOverflow(String),
ModelNetwork(String),
ModelBadRequest(String),
ModelServerError(String),
ModelOther(String),
ToolRuntime(String),
}Expand description
Categorised native-path failure. Each variant maps 1:1 to an
acpx::NativeFaultCategory in core::native_adapter::native_error_to_invoker,
which is in turn projected to a RuntimeError by core::error:: native_fault_to_runtime_error. Keeping the buckets named here lets the
harness crate produce structured errors without taking on any grpc /
proto dependency.
Variants§
Failed(String)
Encode(String)
ChannelClosed
ModelRateLimit(String)
LLM provider returned 429.
ModelAuth(String)
LLM provider returned 401 / 403.
ModelContextOverflow(String)
Prompt + completion exceeded the model’s context window.
ModelNetwork(String)
Transport-level failure (DNS / TCP / TLS / truncated body).
ModelBadRequest(String)
HTTP 400 that is a config error (wrong model name, invalid params). Not retryable — the caller must fix their configuration.
ModelServerError(String)
HTTP 5xx or transient server error. Retryable.
ModelOther(String)
Any other model-side failure not captured above.
ToolRuntime(String)
Sandbox / tool runtime hard error (process spawn refused, envd
unreachable). NOT a ToolFailure — those are domain failures the
model can observe and recover from; this is RD-side infrastructure
breaking under the tool.
Trait Implementations§
Source§impl Debug for NativeHarnessError
impl Debug for NativeHarnessError
Source§impl Display for NativeHarnessError
impl Display for NativeHarnessError
Source§impl Error for NativeHarnessError
impl Error for NativeHarnessError
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()