Enum safe_network::client::Error[][src]

#[non_exhaustive]
pub enum Error {
Show 29 variants AsymmetricDecipherFailure, SymmetricDecipherFailure, ReceivedUnexpectedData, ReceivedUnexpectedEvent, ElderQuery, ElderConnection, NotBootstrapped, InsufficientElderConnections(usize), ReceivingQuery, SendingQuery, QueryReceiverError, NoResponse, NoBlsSectionKey, NoSectionPrefixKnown, UnexpectedMessageOnJoin(String), NotPublicPermissions, NotPrivatePermissions, NoElderListenerEstablished, IncorrectPermissions, UnexpectedQueryResponse(QueryResponse), NotBuiltWithSimulatedPayouts, NetworkDataError(DtError), ErrorMessage { source: ErrorMessage, msg_id: MessageId, }, MessagingProtocol(MessagingError), SelfEncryption(SelfEncryptionError), ConfigError(Error), IoError(Error), QuicP2p(QuicP2pError), Serialisation(Box<ErrorKind>),
}
Expand description

Client Errors

Variants (Non-exhaustive)

This enum is marked as non-exhaustive
Non-exhaustive enums could have additional variants added in future. Therefore, when matching against variants of non-exhaustive enums, an extra wildcard arm must be added to account for any future variants.
AsymmetricDecipherFailure

Asymmetric Key Decryption Failed.

SymmetricDecipherFailure

Symmetric Key Decryption Failed.

ReceivedUnexpectedData

Received unexpected data.

ReceivedUnexpectedEvent

Received unexpected event.

ElderQuery

Could not query elder.

ElderConnection

Could not connect to elder.

NotBootstrapped

Client has not gone trhough qp2p bootstrap process yet

InsufficientElderConnections

Could not connect to sufficient elder to retrieve reliable responses.

Tuple Fields of InsufficientElderConnections

0: usize
ReceivingQuery

Could not query elder.

SendingQuery

Could not send query to elder.

QueryReceiverError

Could not query elder.

NoResponse

Could not query elder.

NoBlsSectionKey

No BLS section key known.

NoSectionPrefixKnown

No section prefix found for session

UnexpectedMessageOnJoin

Unexpected message type receivied while joining.

Tuple Fields of UnexpectedMessageOnJoin

0: String
NotPublicPermissions

Permission set provided is not a PublicPermissionSet.

NotPrivatePermissions

Permission set provided is not a PrivatePermissionSet.

NoElderListenerEstablished

Did not receive an incoming connection listener from qp2p

IncorrectPermissions

Incorrect user permissions were returned

UnexpectedQueryResponse

Unexpected response received

Tuple Fields of UnexpectedQueryResponse

0: QueryResponse
NotBuiltWithSimulatedPayouts

Not in testnet “simulated payout” mode

NetworkDataError

Other types errors

Tuple Fields of NetworkDataError

0: DtError
ErrorMessage

Errors received from the network via sn_messaging

Fields of ErrorMessage

source: ErrorMessage

The source of an error message

msg_id: MessageId

Message ID that was used to send the query

MessagingProtocol

Errors occurred when serialising or deserialising messages

Tuple Fields of MessagingProtocol

0: MessagingError
SelfEncryption

self_enryption errors

Tuple Fields of SelfEncryption

0: SelfEncryptionError
ConfigError

Other types errors

Tuple Fields of ConfigError

0: Error
IoError

Io error.

Tuple Fields of IoError

0: Error
QuicP2p

QuicP2p error.

Tuple Fields of QuicP2p

0: QuicP2pError
Serialisation

Bincode error

Tuple Fields of Serialisation

0: Box<ErrorKind>

Trait Implementations

Formats the value using the given formatter. Read more

Formats the value using the given formatter. Read more

The lower-level source of this error, if any. Read more

🔬 This is a nightly-only experimental API. (backtrace)

Returns a stack backtrace, if available, of where this error occurred. Read more

👎 Deprecated since 1.42.0:

use the Display impl or to_string()

👎 Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Performs the conversion.

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

Should always be Self

Converts the given value to a String. Read more

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.