soil_client/consensus/
error.rs1pub type Result<T> = std::result::Result<T, Error>;
11
12#[derive(Debug, thiserror::Error)]
14pub enum Error {
15 #[error("State unavailable at block {0}")]
17 StateUnavailable(String),
18 #[error("Missing intermediate")]
20 NoIntermediate,
21 #[error("Invalid intermediate")]
23 InvalidIntermediate,
24 #[error("Message signature {0:?} by {1:?} is invalid")]
26 InvalidSignature(Vec<u8>, Vec<u8>),
27 #[error("Current state of blockchain has invalid authorities set")]
29 InvalidAuthoritiesSet,
30 #[error("Invalid justification")]
32 InvalidJustification,
33 #[error("Import failed with outdated justification")]
35 OutdatedJustification,
36 #[error("Import failed: {0}")]
38 ClientImport(String),
39 #[error("Chain lookup failed: {0}")]
41 ChainLookup(String),
42 #[error("Failed to sign: {0}")]
44 CannotSign(String),
45 #[error(transparent)]
47 Other(#[from] Box<dyn std::error::Error + Sync + Send + 'static>),
48}