1use steel::*;
2
3#[repr(u32)]
4#[derive(Debug, Error, Clone, Copy, PartialEq, Eq, IntoPrimitive)]
5pub enum TapeError {
6 #[error("Unknown error")]
7 UnknownError = 0,
8 #[error("The provided tape is in an unexpected state")]
9 UnexpectedState = 1,
10 #[error("The tape write failed")]
11 WriteFailed = 2,
12 #[error("The provided hash is invalid")]
13 SolutionInvalid = 3,
14 #[error("The provided hash did not satisfy the minimum required difficulty")]
15 SolutionTooEasy = 4,
16 #[error("You are trying to submit a solution too early")]
17 SolutionTooEarly = 5,
18 #[error("The provided claim is too large")]
19 ClaimTooLarge = 6,
20 #[error("The epoch has ended and needs to be advanced")]
21 StaleEpoch = 7,
22 #[error("The clock time is invalid")]
23 ClockInvalid = 8,
24 #[error("The maximum supply has been reached")]
25 MaxSupply = 9,
26}
27
28error!(TapeError);