imbibe_persistence/record/
error.rs1use core::{array::TryFromSliceError, num::TryFromIntError};
2
3use cosmrs::ErrorReport;
4
5#[non_exhaustive]
6#[derive(Debug, thiserror::Error)]
7pub enum InvalidValueError {
8 #[error(transparent)]
9 IntConversionError(#[from] TryFromIntError),
10
11 #[error("amount error: amount must be valid u128")]
12 AmountError,
13
14 #[error("cosmrs error: {0}")]
15 Cosmrs(#[from] ErrorReport),
16
17 #[error("empty error: value must be non empty")]
18 Empty,
19
20 #[error("slice error: {0}")]
21 Slice(#[from] TryFromSliceError),
22
23 #[error("invalid time value")]
24 Time,
25
26 #[error("json error: {0}")]
27 Json(#[from] serde_json::Error),
28
29 #[error("other error: {0}")]
30 Other(String),
31}