mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-05-31 01:41:03 +00:00
Add ChainTime associated type (#410)
* add HeaderTimestamp associated type * use Header Timestamp * rename HeaderTimestamp to ChainTime * add unit test * deal with clippy * Apply suggestions from code review Commit review suggestions Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com> * code review * cargo fmt * get rid of additional test runtime * unit test asserts against concrete import context Co-authored-by: Tomasz Drwięga <tomusdrw@users.noreply.github.com>
This commit is contained in:
committed by
Bastian Köcher
parent
253d0d4774
commit
ede0ff8656
@@ -62,6 +62,8 @@ pub enum Error {
|
||||
UnsignedTooFarInTheFuture = 19,
|
||||
/// Trying to finalize sibling of finalized block.
|
||||
TryingToFinalizeSibling = 20,
|
||||
/// Header timestamp is ahead of on-chain timestamp
|
||||
HeaderTimestampIsAhead = 21,
|
||||
}
|
||||
|
||||
impl Error {
|
||||
@@ -88,6 +90,7 @@ impl Error {
|
||||
Error::TransactionsReceiptsMismatch => "Invalid transactions receipts provided",
|
||||
Error::UnsignedTooFarInTheFuture => "The unsigned header is too far in future",
|
||||
Error::TryingToFinalizeSibling => "Trying to finalize sibling of finalized block",
|
||||
Error::HeaderTimestampIsAhead => "Header timestamp is ahead of on-chain timestamp",
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user