Enum brb::error::ValidationError[][src]

pub enum ValidationError<A: Actor<S> + 'static, S: Sig + 'static, V: Debug + Error + 'static> {
Show variants PacketSourceIsNotDot { from: A, dot: Dot<A>, }, MsgDotNotTheNextDot { msg_dot: Dot<A>, expected_dot: Dot<A>, }, SourceAlreadyHasPendingMsg { msg_dot: Dot<A>, next_deliver_dot: Dot<A>, }, MessageFromDifferentGeneration { msg_gen: Generation, gen: Generation, }, SourceIsNotVotingMember { from: A, members: BTreeSet<A>, }, DataTypeFailedValidation(V), InvalidSignature, SignedValidatedForPacketWeDidNotRequest, MsgDotNotNextDotToBeDelivered { msg_dot: Dot<A>, expected_dot: Dot<A>, }, NotEnoughSignaturesToFormQuorum, ProofContainsSignaturesFromNonMembers, ProofContainsInvalidSignatures, DeliveredForPacketWeDidNotInitiate, DeliveredForPacketWeAreNotWaitingOn, PhantomSig(PhantomData<S>),
}
Expand description

Enumerates types of packet validation errors.

Note that all of these errors are generated within the BRB module itself with the exception of DataTypeFailedValidation, which occurs when a BRBDataType validation fails according to its own internal logic.

Variants

PacketSourceIsNotDot

The actor who sent this packet is different from the actor who incremented the dot

Show fields

Fields of PacketSourceIsNotDot

from: A

actor who sent the packet

dot: Dot<A>

the associated dot

MsgDotNotTheNextDot

The dot in this message is out of order

Show fields

Fields of MsgDotNotTheNextDot

msg_dot: Dot<A>

dot of the message

expected_dot: Dot<A>

dot that was expected

SourceAlreadyHasPendingMsg

The source of this message already has a pending message, we can not start a new operation until the first one has completed

Show fields

Fields of SourceAlreadyHasPendingMsg

msg_dot: Dot<A>

dot of the message

next_deliver_dot: Dot<A>

dot of next delivery

MessageFromDifferentGeneration

This message is not from this generation

Show fields

Fields of MessageFromDifferentGeneration

msg_gen: Generation

generation of the message

gen: Generation

present generation

SourceIsNotVotingMember

Source is not a voting member

Show fields

Fields of SourceIsNotVotingMember

from: A

actor that proposed the action

members: BTreeSet<A>

voting members

DataTypeFailedValidation(V)

the datatype failed to validate the operation

InvalidSignature

Signature is invalid

SignedValidatedForPacketWeDidNotRequest

We received a SignedValidated packet for a message we did not request

MsgDotNotNextDotToBeDelivered

Message dot to be applied is not the next message to be delivered

Show fields

Fields of MsgDotNotNextDotToBeDelivered

msg_dot: Dot<A>

the dot in the msg

expected_dot: Dot<A>

the dot we are expecting

NotEnoughSignaturesToFormQuorum

The proof did not contain enough signatures to form quorum

ProofContainsSignaturesFromNonMembers

Proof contains signatures from non-members

ProofContainsInvalidSignatures

Proof contains invalid signatures

DeliveredForPacketWeDidNotInitiate

We received a Op::Delivered packet for a message we did not initiate. Only the initiator should receive these delivered packets.

DeliveredForPacketWeAreNotWaitingOn

We received an Op::Delivered packet for a message we are no longer waiting on. This can happen when we’ve already received a super-majority of Delivered packets and have cleared our local buffer.

PhantomSig(PhantomData<S>)

Phantom, unused.

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.

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.

Performs the conversion.

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.