Enum casper_execution_engine::core::engine_state::Error
source · #[non_exhaustive]pub enum Error {
Show 29 variants
RootNotFound(Digest),
InvalidProtocolVersion(ProtocolVersion),
Genesis(Box<GenesisError>),
WasmPreprocessing(PreprocessingError),
WasmSerialization(SerializationError),
Exec(Error),
Storage(Error),
Authorization,
InsufficientPayment,
GasConversionOverflow,
Deploy,
Finalization,
Bytesrepr(String),
Mint(String),
InvalidKeyVariant,
ProtocolUpgrade(ProtocolUpgradeError),
InvalidDeployItemVariant(String),
CommitError(CommitError),
MissingSystemContractRegistry,
MissingSystemContractHash(String),
MissingChecksumRegistry,
RuntimeStackOverflow,
FailedToGetWithdrawKeys,
FailedToGetStoredWithdraws,
FailedToGetWithdrawPurses,
FailedToRetrieveUnbondingDelay,
FailedToRetrieveEraId,
MissingTrieNodeChildren(Vec<Digest>),
FailedToRetrieveAccumulationPurse,
}
Expand description
Engine state errors.
Variants (Non-exhaustive)§
This enum is marked as non-exhaustive
RootNotFound(Digest)
Specified state root hash is not found.
InvalidProtocolVersion(ProtocolVersion)
Protocol version used in the deploy is invalid.
Genesis(Box<GenesisError>)
Genesis error.
WasmPreprocessing(PreprocessingError)
WASM preprocessing error.
WasmSerialization(SerializationError)
WASM serialization error.
Exec(Error)
Contract execution error.
Storage(Error)
Storage error.
Authorization
Authorization error.
InsufficientPayment
Payment code provided insufficient funds for execution.
GasConversionOverflow
Motes to gas conversion resulted in an overflow.
Deploy
General deploy error.
Finalization
Executing a payment finalization code resulted in an error.
Bytesrepr(String)
Serialization/deserialization error.
Mint(String)
Mint error.
InvalidKeyVariant
Invalid key variant.
ProtocolUpgrade(ProtocolUpgradeError)
Protocol upgrade error.
InvalidDeployItemVariant(String)
Invalid deploy item variant.
CommitError(CommitError)
Commit error.
MissingSystemContractRegistry
Missing system contract registry.
MissingSystemContractHash(String)
Missing system contract hash.
MissingChecksumRegistry
Missing checksum registry.
RuntimeStackOverflow
An attempt to push to the runtime stack while already at the maximum height.
FailedToGetWithdrawKeys
Failed to get the set of Key::Withdraw from global state.
FailedToGetStoredWithdraws
Failed to get the purses stored under Key::Withdraw
FailedToGetWithdrawPurses
Failed to convert the StoredValue into WithdrawPurse.
FailedToRetrieveUnbondingDelay
Failed to retrieve the unbonding delay from the auction state.
FailedToRetrieveEraId
Failed to retrieve the current EraId from the auction state.
MissingTrieNodeChildren(Vec<Digest>)
Failed to put a trie node into global state because some of its children were missing.
FailedToRetrieveAccumulationPurse
Failed to retrieve accumulation purse from handle payment system contract.
Implementations§
Trait Implementations§
source§impl DataSize for Error
impl DataSize for Error
source§const IS_DYNAMIC: bool = true
const IS_DYNAMIC: bool = true
true
, the type has a heap size that can vary at runtime, depending on the actual value.source§const STATIC_HEAP_SIZE: usize = 0usize
const STATIC_HEAP_SIZE: usize = 0usize
IS_DYNAMIC
is false, this is
the total amount of heap memory occupied by the value. Otherwise this is a lower bound.source§fn estimate_heap_size(&self) -> usize
fn estimate_heap_size(&self) -> usize
source§impl Error for Error
impl Error for Error
source§fn source(&self) -> Option<&(dyn Error + 'static)>
fn source(&self) -> Option<&(dyn Error + 'static)>
1.0.0 · source§fn description(&self) -> &str
fn description(&self) -> &str
source§impl From<Box<GenesisError>> for Error
impl From<Box<GenesisError>> for Error
source§fn from(genesis_error: Box<GenesisError>) -> Self
fn from(genesis_error: Box<GenesisError>) -> Self
source§impl From<CommitError> for Error
impl From<CommitError> for Error
source§fn from(source: CommitError) -> Self
fn from(source: CommitError) -> Self
source§impl From<Error> for GetEraValidatorsError
impl From<Error> for GetEraValidatorsError
source§impl From<PreprocessingError> for Error
impl From<PreprocessingError> for Error
source§fn from(source: PreprocessingError) -> Self
fn from(source: PreprocessingError) -> Self
source§impl From<ProtocolUpgradeError> for Error
impl From<ProtocolUpgradeError> for Error
source§fn from(source: ProtocolUpgradeError) -> Self
fn from(source: ProtocolUpgradeError) -> Self
source§impl From<RuntimeStackOverflow> for Error
impl From<RuntimeStackOverflow> for Error
source§fn from(_: RuntimeStackOverflow) -> Self
fn from(_: RuntimeStackOverflow) -> Self
Auto Trait Implementations§
impl RefUnwindSafe for Error
impl Send for Error
impl Sync for Error
impl Unpin for Error
impl UnwindSafe for Error
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
§impl<T> Downcast for Twhere
T: Any,
impl<T> Downcast for Twhere T: Any,
§fn into_any(self: Box<T>) -> Box<dyn Any>
fn into_any(self: Box<T>) -> Box<dyn Any>
Box<dyn Trait>
(where Trait: Downcast
) to Box<dyn Any>
. Box<dyn Any>
can
then be further downcast
into Box<ConcreteType>
where ConcreteType
implements Trait
.§fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
fn into_any_rc(self: Rc<T>) -> Rc<dyn Any>
Rc<Trait>
(where Trait: Downcast
) to Rc<Any>
. Rc<Any>
can then be
further downcast
into Rc<ConcreteType>
where ConcreteType
implements Trait
.§fn as_any(&self) -> &(dyn Any + 'static)
fn as_any(&self) -> &(dyn Any + 'static)
&Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &Any
’s vtable from &Trait
’s.§fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
&mut Trait
(where Trait: Downcast
) to &Any
. This is needed since Rust cannot
generate &mut Any
’s vtable from &mut Trait
’s.