Skip to main content

StateError

Enum StateError 

Source
pub enum StateError {
Show 31 variants Io(Error), Store(StoreError), Node(NodeError), Tree(TreeError), BranchCommit(BranchCommitError), BranchPolicy(BranchPolicyError), Merge(MergeError), BranchRef(BranchRefError), Branch(BranchError), Snapshot(SnapshotError), Checkout(CheckoutError), CapabilityBinding { handle_component: ComponentId, checker_component: ComponentId, }, CapabilityDenied(CapabilityDenied), CapabilityCheck(CapabilityCheckError), DanglingReference { target: ComponentId, state: ReferenceTargetState, }, SynchronizationPoisoned, SchemaNotDeclared { component: ComponentId, }, SchemaAlreadyDeclared { component: ComponentId, }, UnsupportedPolicy { policy: MergePolicy, }, ResolverNotRegistered { name: String, }, ResolverAlreadyRegistered { name: String, }, InstallInProgress { component: ComponentId, }, ArchiveInProgress { component: ComponentId, }, WorkInProgress { component: ComponentId, }, AlreadyActive { component: ComponentId, }, NotActive { component: ComponentId, }, StaleHandle { component: ComponentId, held: u64, current: u64, }, WorkNotFound { branch: String, }, ForeignWorkHandle, CorruptRecord { detail: String, }, Reconcile(ReconcileInconsistency),
}
Expand description

Typed failures from component storage, preserving every substrate error.

Variants§

§

Io(Error)

Filesystem setup failed outside a haematite operation.

§

Store(StoreError)

Node-store operation failed.

§

Node(NodeError)

Empty-node construction failed.

§

Tree(TreeError)

Tree traversal failed.

§

BranchCommit(BranchCommitError)

Branch commit/lifecycle failed outside a more specific category.

§

BranchPolicy(BranchPolicyError)

Engine namespace policy refused an operation, retaining names and kinds.

§

Merge(MergeError)

Engine content merge failed.

§

BranchRef(BranchRefError)

Durable branch-ref operation failed.

§

Branch(BranchError)

Branch handle operation failed.

§

Snapshot(SnapshotError)

Snapshot registry operation failed.

§

Checkout(CheckoutError)

Historical checkout failed.

§

CapabilityBinding

The supplied checker belongs to a different component than the handle.

Fields

§handle_component: ComponentId

Component incarnation represented by the storage handle.

§checker_component: ComponentId

Component whose authority the supplied checker would evaluate.

§

CapabilityDenied(CapabilityDenied)

A fresh check denied this resolution, preserved verbatim from frame-core.

§

CapabilityCheck(CapabilityCheckError)

A fresh check could not produce or publish its verdict.

§

DanglingReference

The named target has no active namespace to resolve.

Fields

§target: ComponentId

Component named by the link.

§state: ReferenceTargetState

Durable target state observed after authority was granted.

§

SynchronizationPoisoned

Internal synchronization was poisoned by a prior panic.

§

SchemaNotDeclared

No schema was declared before install.

Fields

§component: ComponentId

Component whose install lacks a declaration.

§

SchemaAlreadyDeclared

A schema was already fixed for this component’s current lifecycle.

Fields

§component: ComponentId

Component whose pending declaration would be replaced.

§

UnsupportedPolicy

The published engine cannot execute the declared vocabulary entry.

Fields

§policy: MergePolicy

Policy refused at schema declaration.

§

ResolverNotRegistered

A custom policy named a resolver absent at declaration time.

Fields

§name: String

Stable resolver name that was not registered.

§

ResolverAlreadyRegistered

A resolver registration would silently replace an existing function.

Fields

§name: String

Stable resolver name already bound in this process.

§

InstallInProgress

An install is already executing for this identity.

Fields

§component: ComponentId

Component with an active install transition.

§

ArchiveInProgress

An archive is already executing for this identity.

Fields

§component: ComponentId

Component with an active archive transition.

§

WorkInProgress

A fork or merge is already executing for this identity.

Fields

§component: ComponentId

Component with an active Work operation.

§

AlreadyActive

Install was requested for an active namespace.

Fields

§component: ComponentId

Component whose namespace is already Active.

§

NotActive

The component has no active namespace.

Fields

§component: ComponentId

Component for which active storage was required.

§

StaleHandle

A handle’s captured incarnation no longer owns the branch name.

Fields

§component: ComponentId

Component whose name was reused.

§held: u64

Incarnation captured by the handle.

§current: u64

Durable current incarnation.

§

WorkNotFound

A requested Work branch is not outstanding.

Fields

§branch: String

Durable Work branch name that was absent.

§

ForeignWorkHandle

A Work handle came from another store, component, or incarnation.

§

CorruptRecord

A branch/archive key did not have Frame’s fixed-width encoding.

Fields

§detail: String

Exact codec or durable-invariant failure.

§

Reconcile(ReconcileInconsistency)

Boot found a durable state it cannot safely repair.

Trait Implementations§

Source§

impl Debug for StateError

Source§

fn fmt(&self, f: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Display for StateError

Source§

fn fmt(&self, formatter: &mut Formatter<'_>) -> Result

Formats the value using the given formatter. Read more
Source§

impl Error for StateError

Source§

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

👎Deprecated since 1.42.0:

use the Display impl or to_string()

1.0.0 · Source§

fn cause(&self) -> Option<&dyn Error>

👎Deprecated since 1.33.0:

replaced by Error::source, which can support downcasting

Source§

fn provide<'a>(&'a self, request: &mut Request<'a>)

🔬This is a nightly-only experimental API. (error_generic_member_access)
Provides type-based access to context intended for error reports. Read more
Source§

impl From<BranchCommitError> for StateError

Source§

fn from(error: BranchCommitError) -> Self

Converts to this type from the input type.
Source§

impl From<BranchError> for StateError

Source§

fn from(error: BranchError) -> Self

Converts to this type from the input type.
Source§

impl From<BranchRefError> for StateError

Source§

fn from(error: BranchRefError) -> Self

Converts to this type from the input type.
Source§

impl From<CapabilityCheckError> for StateError

Source§

fn from(error: CapabilityCheckError) -> Self

Converts to this type from the input type.
Source§

impl From<CheckoutError> for StateError

Source§

fn from(error: CheckoutError) -> Self

Converts to this type from the input type.
Source§

impl From<Error> for StateError

Source§

fn from(error: Error) -> Self

Converts to this type from the input type.
Source§

impl From<NodeError> for StateError

Source§

fn from(error: NodeError) -> Self

Converts to this type from the input type.
Source§

impl From<ReconcileInconsistency> for StateError

Source§

fn from(error: ReconcileInconsistency) -> Self

Converts to this type from the input type.
Source§

impl From<SnapshotError> for StateError

Source§

fn from(error: SnapshotError) -> Self

Converts to this type from the input type.
Source§

impl From<StoreError> for StateError

Source§

fn from(error: StoreError) -> Self

Converts to this type from the input type.
Source§

impl From<TreeError> for StateError

Source§

fn from(error: TreeError) -> Self

Converts to this type from the input type.

Auto Trait Implementations§

Blanket Implementations§

Source§

impl<T> Any for T
where T: 'static + ?Sized,

Source§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
Source§

impl<T> Borrow<T> for T
where T: ?Sized,

Source§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
Source§

impl<T> BorrowMut<T> for T
where T: ?Sized,

Source§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
Source§

impl<T> From<T> for T

Source§

fn from(t: T) -> T

Returns the argument unchanged.

Source§

impl<T> Instrument for T

Source§

fn instrument(self, span: Span) -> Instrumented<Self>

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

fn in_current_span(self) -> Instrumented<Self>

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

impl<T, U> Into<U> for T
where U: From<T>,

Source§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

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

impl<T> ToString for T
where T: Display + ?Sized,

Source§

fn to_string(&self) -> String

Converts the given value to a String. Read more
Source§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

Source§

type Error = Infallible

The type returned in the event of a conversion error.
Source§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
Source§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

Source§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
Source§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.
Source§

impl<T> WithSubscriber for T

Source§

fn with_subscriber<S>(self, subscriber: S) -> WithDispatch<Self>
where S: Into<Dispatch>,

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more
Source§

fn with_current_subscriber(self) -> WithDispatch<Self>

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more