Enum breez_sdk_core::lightning::util::errors::APIError
pub enum APIError {
APIMisuseError {
err: String,
},
FeeRateTooHigh {
err: String,
feerate: u32,
},
InvalidRoute {
err: String,
},
ChannelUnavailable {
err: String,
},
MonitorUpdateInProgress,
IncompatibleShutdownScript {
script: ShutdownScript,
},
}
Expand description
Indicates an error on the client’s part (usually some variant of attempting to use too-low or too-high values)
Variants§
APIMisuseError
Indicates the API was wholly misused (see err for more). Cases where these can be returned are documented, but generally indicates some precondition of a function was violated.
FeeRateTooHigh
Due to a high feerate, we were unable to complete the request. For example, this may be returned if the feerate implies we cannot open a channel at the requested value, but opening a larger channel would succeed.
InvalidRoute
A malformed Route was provided (eg overflowed value, node id mismatch, overly-looped route, too-many-hops, etc).
We were unable to complete the request as the Channel required to do so is unable to complete the request (or was not found). This can take many forms, including disconnected peer, channel at capacity, channel shutting down, etc.
MonitorUpdateInProgress
An attempt to call chain::Watch::watch_channel
/chain::Watch::update_channel
returned a ChannelMonitorUpdateStatus::InProgress
indicating the persistence of a
monitor update is awaiting async resolution. Once it resolves the attempted action should
complete automatically.
IncompatibleShutdownScript
SignerProvider::get_shutdown_scriptpubkey
returned a shutdown scriptpubkey incompatible
with the channel counterparty as negotiated in InitFeatures
.
Using a SegWit v0 script should resolve this issue. If you cannot, you won’t be able to open a channel or cooperatively close one with this peer (and will have to force-close instead).
Fields
script: ShutdownScript
The incompatible shutdown script.
Trait Implementations§
§impl MaybeReadable for APIError
impl MaybeReadable for APIError
§impl Writeable for APIError
impl Writeable for APIError
impl Eq for APIError
impl StructuralPartialEq for APIError
Auto Trait Implementations§
impl Freeze for APIError
impl RefUnwindSafe for APIError
impl Send for APIError
impl Sync for APIError
impl Unpin for APIError
impl UnwindSafe for APIError
Blanket Implementations§
§impl<T> AnySync for T
impl<T> AnySync for T
§impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedExplicit<'a, E> for Twhere
T: 'a,
§impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
impl<'a, T, E> AsTaggedImplicit<'a, E> for Twhere
T: 'a,
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> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)§impl<T> Downcast for Twhere
T: AsAny + ?Sized,
impl<T> Downcast for Twhere
T: AsAny + ?Sized,
§fn downcast_ref<T>(&self) -> Option<&T>where
T: AsAny,
fn downcast_ref<T>(&self) -> Option<&T>where
T: AsAny,
Any
.§fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: AsAny,
fn downcast_mut<T>(&mut self) -> Option<&mut T>where
T: AsAny,
Any
.source§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
source§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
§impl<Q, K> Equivalent<K> for Q
impl<Q, K> Equivalent<K> for Q
§fn equivalent(&self, key: &K) -> bool
fn equivalent(&self, key: &K) -> bool
key
and return true
if they are equal.§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
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::Request