BatchInterrupted
Event v120 → current #0Emitted when a batch did not complete fully - gives index of first failing call .
View events on chainUseful for: developersanalyticswallets
The Big Picture
When batching multiple calls, this event tells you where things went wrong.
Use Cases
- Debug which call in a batch failed
From Chain Metadata
Batch of dispatches did not complete fully. Index of first failing dispatch given, as well as the error.
Triggers
Effects
Postconditions
- Calls up to (but not including) index executed
Side Effects
- Contains error details for debugging
Event Data
| # | Name | Type | Description |
|---|---|---|---|
| 0 | index | u32 | Index of the first failing call in the batch |
| 1 | error | DispatchError | Error that caused the batch to be interrupted |
Code Examples
import { createClient, Binary } from "polkadot-api";
import { getWsProvider } from "polkadot-api/ws";
import { sub } from "@polkadot-api/descriptors"; // generated by: npx papi add sub -w wss://entrypoint-finney.opentensor.ai:443
const client = createClient(getWsProvider("wss://entrypoint-finney.opentensor.ai:443"));
const api = client.getTypedApi(sub);
// Subscribe to BatchInterrupted events
client.finalizedBlock$.subscribe(async (block) => {
const events = await api.event.Utility.BatchInterrupted.get(block.hash);
for (const evt of events) {
console.log("BatchInterrupted:", evt.payload);
}
});On-Chain Activity
Emission Frequency
●●●○○○ Active 100K–1M emissions
Regular feature-level activity
#40 most emitted event
As of block 7,429,232
Runtime Info
- Pallet Index
- 11
- Event Index
- 0
- First Version
- v120
- Current Version
- v411