pub trait PalletError: Encode + Decode {
    const MAX_ENCODED_SIZE: usize;
}
Expand description

Trait indicating that the implementing type is going to be included as a field in a variant of the #[pallet::error] enum type.

Notes

The pallet error enum has a maximum encoded size as defined by frame_support::MAX_MODULE_ERROR_ENCODED_SIZE. If the pallet error type exceeds this size limit, a static assertion during compilation will fail. The compilation error will be in the format of error[E0080]: evaluation of constant value failed due to the usage of const assertions.

Required Associated Constants§

source

const MAX_ENCODED_SIZE: usize

The maximum encoded size for the implementing type.

This will be used to check whether the pallet error type is less than or equal to frame_support::MAX_MODULE_ERROR_ENCODED_SIZE, and if it is, a compilation error will be thrown.

Implementations on Foreign Types§

source§

impl PalletError for i16

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError, TupleElement13: PalletError, TupleElement14: PalletError, TupleElement15: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14, TupleElement15)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11)

source§

impl PalletError for u8

source§

impl<TupleElement0: PalletError> PalletError for (TupleElement0,)

source§

impl PalletError for i64

source§

impl PalletError for Duration

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7)

source§

impl PalletError for Compact<u32>

source§

impl<T: PalletError> PalletError for Option<T>

source§

impl PalletError for i32

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2)

source§

impl PalletError for bool

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5)

source§

impl PalletError for i128

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9)

source§

impl PalletError for u128

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3)

source§

impl PalletError for i8

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8)

source§

impl PalletError for ()

source§

impl PalletError for u32

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError, TupleElement13: PalletError, TupleElement14: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14)

source§

impl PalletError for Compact<u16>

source§

impl PalletError for Compact<u128>

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError, TupleElement13: PalletError, TupleElement14: PalletError, TupleElement15: PalletError, TupleElement16: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14, TupleElement15, TupleElement16)

source§

impl PalletError for u16

source§

impl PalletError for Compact<u64>

source§

impl PalletError for Compact<u8>

source§

impl<T: PalletError> PalletError for Range<T>

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError> PalletError for (TupleElement0, TupleElement1)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError, TupleElement13: PalletError, TupleElement14: PalletError, TupleElement15: PalletError, TupleElement16: PalletError, TupleElement17: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13, TupleElement14, TupleElement15, TupleElement16, TupleElement17)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError, TupleElement5: PalletError, TupleElement6: PalletError, TupleElement7: PalletError, TupleElement8: PalletError, TupleElement9: PalletError, TupleElement10: PalletError, TupleElement11: PalletError, TupleElement12: PalletError, TupleElement13: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4, TupleElement5, TupleElement6, TupleElement7, TupleElement8, TupleElement9, TupleElement10, TupleElement11, TupleElement12, TupleElement13)

source§

impl<TupleElement0: PalletError, TupleElement1: PalletError, TupleElement2: PalletError, TupleElement3: PalletError, TupleElement4: PalletError> PalletError for (TupleElement0, TupleElement1, TupleElement2, TupleElement3, TupleElement4)

source§

impl<T: PalletError, const N: usize> PalletError for [T; N]

source§

impl PalletError for u64

Implementors§