diff --git a/bittensor/core/extrinsics/asyncex/coldkey_swap.py b/bittensor/core/extrinsics/asyncex/coldkey_swap.py index 6fb74ff393..3b8044afd6 100644 --- a/bittensor/core/extrinsics/asyncex/coldkey_swap.py +++ b/bittensor/core/extrinsics/asyncex/coldkey_swap.py @@ -396,7 +396,9 @@ async def swap_coldkey_announced_extrinsic( # nonce). Drop the in-process nonce cache entry so the next extrinsic # signed by this ss58 re-fetches from the chain instead of incrementing # a stale value. - subtensor.substrate._nonces.pop(wallet.coldkeypub.ss58_address, None) + subtensor.substrate.clear_nonce_cache_for_account( + wallet.coldkeypub.ss58_address + ) logging.debug("[green]Coldkey swap executed successfully.[/green]") else: logging.error(f"[red]{response.message}[/red]") diff --git a/bittensor/core/extrinsics/asyncex/sudo.py b/bittensor/core/extrinsics/asyncex/sudo.py index ef49dd1204..066aebc4a1 100644 --- a/bittensor/core/extrinsics/asyncex/sudo.py +++ b/bittensor/core/extrinsics/asyncex/sudo.py @@ -113,7 +113,7 @@ async def swap_coldkey_extrinsic( # nonce). Drop the in-process nonce cache entry so the next extrinsic # signed by this ss58 re-fetches from the chain instead of incrementing # a stale value. - subtensor.substrate._nonces.pop(old_coldkey_ss58, None) + subtensor.substrate.clear_nonce_cache_for_account(old_coldkey_ss58) return response diff --git a/pyproject.toml b/pyproject.toml index 360932a3a4..322cd80603 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -33,7 +33,7 @@ dependencies = [ "uvicorn", "bittensor-drand>=1.3.0,<2.0.0", "bittensor-wallet==4.0.1", - "async-substrate-interface>=2.0.3,<3.0.0", + "async-substrate-interface>=2.0.4,<3.0.0", ] [project.optional-dependencies]