TransactionalError

Variant 30 v393

sp_runtime::TransactionalError

About This Type

Error from transactional storage operations.

Returned when transactional storage layers reach their limit or are used incorrectly. Rare in practice; mainly relevant to runtime developers.

Variants (2)

IndexNameFieldsDocs
0LimitReachednone
1NoLayernone

SCALE Encoding

Rule
1-byte variant index followed by variant-specific field data. 2 possible variants.
Size
variable (1+ bytes)

Examples

LimitReached
0x00
00 Variant index 0 = LimitReached
NoLayer
0x01
01 Variant index 1 = NoLayer

Code Examples

import { TypeRegistry } from "@polkadot/types";

const registry = new TypeRegistry();

// Encode TransactionalError — variant "LimitReached"
const value = registry.createType("TransactionalError", "LimitReached");
console.log("Hex:", value.toHex());

Referenced By (1)

Type Information

Type ID
30
Kind
Variant
Path
sp_runtime::TransactionalError
Runtime
v393