Preimage::Error
Variant 481 v393pallet_preimage::pallet::Error
The `Error` enum of this pallet.
About This Type
Error enum for the Error pallet.
Contains all error types that the Error pallet can return when a call fails.
Variants (8)
| Index | Name | Fields | Docs |
|---|---|---|---|
| 0 | TooBig | none | Preimage is too large to store on-chain. |
| 1 | AlreadyNoted | none | Preimage has already been noted on-chain. |
| 2 | NotAuthorized | none | The user is not authorized to perform this action. |
| 3 | NotNoted | none | The preimage cannot be removed since it has not yet been noted. |
| 4 | Requested | none | A preimage may not be removed when there are outstanding requests. |
| 5 | NotRequested | none | The preimage request cannot be removed since no outstanding requests exist. |
| 6 | TooMany | none | More than `MAX_HASH_UPGRADE_BULK_COUNT` hashes were requested to be upgraded at once. |
| 7 | TooFew | none | Too few hashes were requested to be upgraded (i.e. zero). |
SCALE Encoding
- Rule
- 1-byte variant index followed by variant-specific field data. 8 possible variants.
- Size
- variable (1+ bytes)
Examples
TooBig
0x0000 Variant index 0 = TooBigAlreadyNoted
0x0101 Variant index 1 = AlreadyNotedNotAuthorized
0x0202 Variant index 2 = NotAuthorizedCode Examples
import { TypeRegistry } from "@polkadot/types";
const registry = new TypeRegistry();
// Encode Preimage::Error — variant "TooBig"
const value = registry.createType("Preimage::Error", "TooBig");
console.log("Hex:", value.toHex());Type Parameters
T
Referenced By (21)
#726 RuntimeError via System#726 RuntimeError via Grandpa#726 RuntimeError via Balances#726 RuntimeError via SubtensorModule#726 RuntimeError via Utility#726 RuntimeError via Sudo#726 RuntimeError via Multisig#726 RuntimeError via Preimage#726 RuntimeError via Scheduler#726 RuntimeError via Proxy#726 RuntimeError via Registry#726 RuntimeError via Commitments#726 RuntimeError via AdminUtils#726 RuntimeError via SafeMode#726 RuntimeError via Ethereum#726 RuntimeError via EVM#726 RuntimeError via Drand#726 RuntimeError via Crowdloan#726 RuntimeError via Swap#726 RuntimeError via Contracts
and 1 more...
Also See
Type Information
- Type ID
- 481
- Kind
- Variant
- Path
- pallet_preimage::pallet::Error
- Runtime
- v393