mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-30 13:07:56 +00:00
use thiserror instead of derive_more for error handling (#10696)
* use thiserror instead of derive_more for error handling Signed-off-by: koushiro <koushiro.cqx@gmail.com> * Update utils/prometheus/src/lib.rs * Update utils/prometheus/src/lib.rs Co-authored-by: Bastian Köcher <bkchr@users.noreply.github.com>
This commit is contained in:
@@ -166,11 +166,13 @@ pub struct EpochAuthorship {
|
||||
}
|
||||
|
||||
/// Errors encountered by the RPC
|
||||
#[derive(Debug, derive_more::Display, derive_more::From)]
|
||||
#[derive(Debug, thiserror::Error)]
|
||||
pub enum Error {
|
||||
/// Consensus error
|
||||
Consensus(ConsensusError),
|
||||
#[error(transparent)]
|
||||
Consensus(#[from] ConsensusError),
|
||||
/// Errors that can be formatted as a String
|
||||
#[error("{0}")]
|
||||
StringError(String),
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user