This error was removed in v150
This error is no longer present in the current runtime. Existed from v101 to v150. Shown here for historical reference.
NetworkDoesNotExist
Error Removed v101 → v127, v133 → v150 (removed) 7.0The subnet (netuid ) you specified doesn't exist on the network.
Why This Error Exists
Every operation that targets a specific subnet requires a valid netuid. Subnets can be created and dissolved, so the list of valid netuids changes over time. Mainnet and testnet have different subnet configurations.
Deep Dive
NetworksAdded is a boolean map of netuid -> bool. If NetworksAdded(netuid) returns false or None, that subnet doesn't exist. The root network is always netuid=0. Other subnets are numbered 1, 2, 3, etc., but not all numbers are active - dissolved subnets leave gaps. TotalNetworks tells you how many exist, not the highest netuid.
Debugging Example
You call register(netuid=99, ...). Error: NetworkDoesNotExist. You query NetworksAdded(99) - returns false. Query TotalNetworks - returns 45. So there are 45 subnets, but netuid 99 isn't one of them. Iterate NetworksAdded(0), NetworksAdded(1), etc. to find valid netuids, or check the Bittensor subnet list.
Prevention Tips
- Validate netuid by querying NetworksAdded(netuid) before any subnet operation
- Subscribe to NetworkAdded/NetworkRemoved events to track subnet changes
- Use a known subnet list from documentation or community resources
What This Means
The subnet (netuid) you specified doesn't exist on the network.
Common Causes
- Typo in netuid parameter
- Subnet was removed or never created
- Using testnet netuid on mainnet or vice versa
How to Fix
- Check SubtensorModule.NetworksAdded to see valid netuids
- Query SubtensorModule.TotalNetworks for total count
- Verify you're on the correct network (mainnet vs testnet)
Storage to Check
Version History
Runtime Info
- Pallet Index
- 7
- Error Index
- 0
- Error Code
- 7.0
- Removed In
- v150