pub enum RunCommandError {
ApiError(Error),
InvalidRequestBody(Error),
WebSocketSend(Error),
WebSocketRecv(Error),
ModelingApiFailure {
request_id: Option<Uuid>,
errors: Vec<ApiError>,
},
WebSocketClosed,
WrongId,
TimeOutWaitingForResponse,
ServerSentWrongType,
ActorFailed,
}
Expand description
Errors from running a modeling command.
Variants§
ApiError(Error)
Error from the KittyCAD API client.
InvalidRequestBody(Error)
Request body could not be serialized.
WebSocketSend(Error)
Could not send message via WebSocket.
WebSocketRecv(Error)
Could not receive message via WebSocket.
ModelingApiFailure
Modeling API request failed.
Fields
WebSocketClosed
WebSocket closed unexpectedly.
WrongId
Received a response for an unexpected request ID.
TimeOutWaitingForResponse
Timed out waiting for a response.
ServerSentWrongType
Server returned the wrong type.
ActorFailed
Actor has failed
Implementations§
Source§impl RunCommandError
impl RunCommandError
Sourcepub fn should_end_session(&self) -> bool
pub fn should_end_session(&self) -> bool
Does this error indicate that the session has become unhealthy and should be restarted (i.e. ended and started again)?
Trait Implementations§
Source§impl Debug for RunCommandError
impl Debug for RunCommandError
Source§impl Display for RunCommandError
impl Display for RunCommandError
Source§impl Error for RunCommandError
impl Error for RunCommandError
Source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
Returns the lower-level source of this error, if any. Read more
1.0.0 · Source§fn description(&self) -> &str
fn description(&self) -> &str
👎Deprecated since 1.42.0: use the Display impl or to_string()
Source§impl From<Error> for RunCommandError
impl From<Error> for RunCommandError
Auto Trait Implementations§
impl !Freeze for RunCommandError
impl !RefUnwindSafe for RunCommandError
impl Send for RunCommandError
impl Sync for RunCommandError
impl Unpin for RunCommandError
impl !UnwindSafe for RunCommandError
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
Mutably borrows from an owned value. Read more
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
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>
Converts
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>
Converts
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> IntoResult<T> for T
impl<T> IntoResult<T> for T
type Err = Infallible
fn into_result(self) -> Result<T, <T as IntoResult<T>>::Err>
Source§impl<T> IntoResult<T> for T
impl<T> IntoResult<T> for T
type Err = Infallible
fn into_result(self) -> Result<T, <T as IntoResult<T>>::Err>
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.