pub enum PathfinderError {
Imbalanced {
terminal_sum: U192,
expected: U192,
},
Transport(CirclesRpcError),
RpcResponse(String),
}Expand description
Errors that can occur during pathfinding and flow matrix operations.
Variants§
Imbalanced
Flow matrix terminal sum doesn’t match expected value.
This occurs when the sum of all terminal flow edges (edges that reach the destination) doesn’t equal the expected transfer amount. This usually indicates an issue with the transfer path or RPC data.
§Example
PathfinderError::Imbalanced {
terminal_sum: 800,
expected: 1000
}Fields
Transport(CirclesRpcError)
RPC transport/client error (HTTP/WS or deserialization).
RpcResponse(String)
JSON-RPC payload error returned by the server or an invalid response body.
Trait Implementations§
Source§impl Debug for PathfinderError
impl Debug for PathfinderError
Source§impl Display for PathfinderError
impl Display for PathfinderError
Source§impl Error for PathfinderError
impl Error for PathfinderError
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<CirclesRpcError> for PathfinderError
impl From<CirclesRpcError> for PathfinderError
Source§fn from(source: CirclesRpcError) -> Self
fn from(source: CirclesRpcError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl Freeze for PathfinderError
impl !RefUnwindSafe for PathfinderError
impl Send for PathfinderError
impl Sync for PathfinderError
impl Unpin for PathfinderError
impl !UnwindSafe for PathfinderError
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> 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> 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.