mirror of
https://github.com/pezkuwichain/pezkuwi-subxt.git
synced 2026-04-27 02:17:58 +00:00
Allow runtime to return transaction validation error codes (#1534)
* Allow runtime to return more detailed transaction validation errors. * Re-use ApplyError codes and update test-runtime. * Fix pool tests. * Revert using Compact for validity.
This commit is contained in:
@@ -33,7 +33,7 @@ pub type TransactionTag = Vec<u8>;
|
||||
#[cfg_attr(feature = "std", derive(Debug))]
|
||||
pub enum TransactionValidity {
|
||||
/// Transaction is invalid. Details are described by the error code.
|
||||
Invalid,
|
||||
Invalid(i8),
|
||||
/// Transaction is valid.
|
||||
Valid {
|
||||
/// Priority of the transaction.
|
||||
@@ -60,5 +60,5 @@ pub enum TransactionValidity {
|
||||
longevity: TransactionLongevity,
|
||||
},
|
||||
/// Transaction validity can't be determined.
|
||||
Unknown,
|
||||
Unknown(i8),
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user