Phase
Variant 101 v393frame_system::Phase
About This Type
DispatchError bundled with post-dispatch weight info.
When an extrinsic fails, this carries both the error and the actual weight consumed, enabling partial fee refunds for the weight that was not used.
Variants (3)
| Index | Name | Fields | Docs |
|---|---|---|---|
| 0 | ApplyExtrinsic | ||
| 1 | Finalization | none | |
| 2 | Initialization | none |
SCALE Encoding
- Rule
- 1-byte variant index followed by variant-specific field data. 3 possible variants.
- Size
- variable (1+ bytes)
Examples
ApplyExtrinsic = ApplyExtrinsic(u32)
0x00<field0>00 Variant index 0 = ApplyExtrinsicfield 0 field0: u32Finalization
0x0101 Variant index 1 = FinalizationInitialization
0x0202 Variant index 2 = InitializationCode Examples
import { TypeRegistry } from "@polkadot/types";
const registry = new TypeRegistry();
// Encode Phase — variant "ApplyExtrinsic"
const value = registry.createType("Phase", { ApplyExtrinsic: { value: 1000000 } });
console.log("Hex:", value.toHex());Referenced By (1)
Type Information
- Type ID
- 101
- Kind
- Variant
- Path
- frame_system::Phase
- Runtime
- v393