ColdkeySwapReset

Event v385 → v402, v411 → v422, v423 → v440, v441 → current #71

Emitted when root clears a coldkey swap announcement and any dispute, returning the account to normal.

View events on chain
Useful for: analyticsdeveloperswallets

The Big Picture

The only exit from a disputed coldkey, and the governance end of the dispute mechanism. It resolves the state without performing the rotation.

Why This Matters

An announcement that ends in a reset produced no rotation. For lifecycle accounting there are three terminal outcomes, not one: executed, self-cleared, or reset.

Example Scenario

A disputed coldkey is halted entirely. After off-chain resolution, root calls reset_coldkey_swap. ColdkeySwapReset fires and the account can transact again with its original key.

Use Cases

  • Detect resolution of a disputed rotation
  • Close out a lifecycle that ended in neither a swap nor a self-clear

How to Use This Event

  • → Treat as terminal for the announcement, alongside ColdkeySwapped and ColdkeySwapCleared

From Chain Metadata

A coldkey swap has been reset.

Triggers

Preconditions

  • Root origin

Effects

Postconditions

  • ColdkeySwapAnnouncements is cleared for this coldkey
  • ColdkeySwapDisputes is cleared for this coldkey
  • The account is unfrozen

Side Effects

  • Any pending rotation is discarded; the coldkey is not swapped

Event Data

#NameTypeDescription
0
who
AccountId who: Account address (32 bytes, SS58-encoded) (hex -> SS58)

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 ColdkeySwapReset events
client.finalizedBlock$.subscribe(async (block) => {
  const events = await api.event.SubtensorModule.ColdkeySwapReset.get(block.hash);
  for (const evt of events) {
    console.log("ColdkeySwapReset:", evt.payload);
  }
});

Version History

v385 block 7,782,670 1 args
v411 block 8,283,784 1 args
v423 block 8,486,593 1 args
v441 block 8,765,683 1 args Current

Runtime Info

View Source
Pallet Index
7
Event Index
71
First Version
v385
Current Version
v472