pub enum NodeError {
Show 14 variants
PeerNotFound(String),
AmbiguousPeer {
query: String,
candidates: Vec<String>,
},
PeerGone(String),
ConnectionFailed(String),
SendFailed(String),
Envelope(EnvelopeError),
Session(SessionError),
Network(NetworkError),
Transport(TransportError),
NotImplemented(String),
ReservedPort(u16),
Stopped,
BuildError(String),
Io(Error),
}Expand description
Errors from the Node API.
Variants§
PeerNotFound(String)
The requested peer is not known.
AmbiguousPeer
The query matched more than one peer (RFC 022 mesh.peer).
Fields
PeerGone(String)
The peer handle is no longer usable (left the mesh).
ConnectionFailed(String)
Failed to establish a connection.
SendFailed(String)
Failed to send a message.
Envelope(EnvelopeError)
Envelope encoding/decoding error.
Session(SessionError)
Session layer error.
Network(NetworkError)
Network layer error.
Transport(TransportError)
Transport layer error.
NotImplemented(String)
The requested feature is not yet implemented.
ReservedPort(u16)
The port is reserved by truffle’s own listeners.
Stopped
The node has been stopped.
BuildError(String)
Builder configuration error.
Io(Error)
I/O error from the builder (state dir creation, device-id persistence).
Trait Implementations§
Source§impl Error for NodeError
impl Error for NodeError
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<EnvelopeError> for NodeError
impl From<EnvelopeError> for NodeError
Source§fn from(source: EnvelopeError) -> Self
fn from(source: EnvelopeError) -> Self
Converts to this type from the input type.
Source§impl From<NetworkError> for NodeError
impl From<NetworkError> for NodeError
Source§fn from(source: NetworkError) -> Self
fn from(source: NetworkError) -> Self
Converts to this type from the input type.
Source§impl From<SessionError> for NodeError
impl From<SessionError> for NodeError
Source§fn from(source: SessionError) -> Self
fn from(source: SessionError) -> Self
Converts to this type from the input type.
Source§impl From<TransportError> for NodeError
impl From<TransportError> for NodeError
Source§fn from(source: TransportError) -> Self
fn from(source: TransportError) -> Self
Converts to this type from the input type.
Auto Trait Implementations§
impl !RefUnwindSafe for NodeError
impl !UnwindSafe for NodeError
impl Freeze for NodeError
impl Send for NodeError
impl Sync for NodeError
impl Unpin for NodeError
impl UnsafeUnpin for NodeError
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