pub enum AcpClientError {
InvalidConfig(String),
Spawn(Error),
Handshake {
step: HandshakeStep,
source: Error,
},
SendFailed(Error),
DriverBusy,
DriverDied,
Timeout,
Closed,
Cancelled,
Sdk(Error),
}Expand description
Errors returned by the ACP sub-agent client.
Variants§
InvalidConfig(String)
The command string was empty or could not be shell-split.
Spawn(Error)
The subprocess failed to spawn.
Handshake
The ACP handshake failed at the named step.
SendFailed(Error)
The prompt or notification could not be sent to the sub-agent.
DriverBusy
A second command was sent while the driver was already servicing a read.
The caller should wait for the in-flight operation to complete before retrying.
DriverDied
The driver task exited unexpectedly before the operation could complete.
This usually means the subprocess crashed or the transport was closed.
Timeout
The operation timed out.
Closed
The session was closed by a call to super::SubagentHandle::close or via
a [super::SubagentCommand::Close] command.
Cancelled
A cancel was requested and the sub-agent acknowledged it by returning a
StopReason::Cancelled update.
Sdk(Error)
Underlying SDK/protocol error not covered by the variants above.
Trait Implementations§
Source§impl Debug for AcpClientError
impl Debug for AcpClientError
Source§impl Display for AcpClientError
impl Display for AcpClientError
Source§impl Error for AcpClientError
impl Error for AcpClientError
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()
Auto Trait Implementations§
impl Freeze for AcpClientError
impl !RefUnwindSafe for AcpClientError
impl Send for AcpClientError
impl Sync for AcpClientError
impl Unpin for AcpClientError
impl UnsafeUnpin for AcpClientError
impl !UnwindSafe for AcpClientError
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§impl<T> IntoMaybeUndefined<T> for T
impl<T> IntoMaybeUndefined<T> for T
fn into_maybe_undefined(self) -> MaybeUndefined<T>
Source§impl<T> IntoOption<T> for T
impl<T> IntoOption<T> for T
fn into_option(self) -> Option<T>
Source§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
Source§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
T in a tonic::RequestSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<T> PolicyExt for Twhere
T: ?Sized,
impl<T> PolicyExt for Twhere
T: ?Sized,
Source§impl<T> ToStringFallible for Twhere
T: Display,
impl<T> ToStringFallible for Twhere
T: Display,
Source§fn try_to_string(&self) -> Result<String, TryReserveError>
fn try_to_string(&self) -> Result<String, TryReserveError>
ToString::to_string, but without panic on OOM.