Skip to content

Commit 9d4509f

Browse files
author
Roman
committed
debug issue
1 parent 8e71028 commit 9d4509f

File tree

1 file changed

+5
-4
lines changed

1 file changed

+5
-4
lines changed

tests/e2e_tests/test_metagraph.py

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -49,7 +49,7 @@ def test_metagraph(subtensor, alice_wallet, bob_wallet, dave_wallet):
4949
alice_subnet_netuid = 2
5050

5151
# Register the subnet through Alice
52-
assert subtensor.register_subnet(alice_wallet), "Unable to register the subnet"
52+
assert subtensor.register_subnet(alice_wallet, True, True), "Unable to register the subnet"
5353

5454
# Verify subnet was created successfully
5555
assert subtensor.subnet_exists(alice_subnet_netuid), (
@@ -74,9 +74,6 @@ def test_metagraph(subtensor, alice_wallet, bob_wallet, dave_wallet):
7474
# Refresh the metagraph
7575
metagraph.sync(subtensor=subtensor)
7676

77-
# wait for updated information to arrive (important for low resource docker)
78-
subtensor.wait_for_block(subtensor.block + 10)
79-
8077
# Assert metagraph has Alice and Bob neurons
8178
assert len(metagraph.uids) == 2, "Metagraph doesn't have exactly 2 neurons"
8279
assert metagraph.hotkeys[0] == alice_wallet.hotkey.ss58_address, (
@@ -97,9 +94,13 @@ def test_metagraph(subtensor, alice_wallet, bob_wallet, dave_wallet):
9794

9895
# Fetch neuron info of Bob through subtensor and metagraph
9996
neuron_info_bob = subtensor.neuron_for_uid(uid, netuid=alice_subnet_netuid)
97+
print(">>> neuron_info_bob", neuron_info_bob)
10098
metagraph_dict = neuron_to_dict(metagraph.neurons[uid])
10199
subtensor_dict = neuron_to_dict(neuron_info_bob)
102100

101+
print(">>> metagraph_dict", metagraph_dict)
102+
print(">>> subtensor_dict", subtensor_dict)
103+
103104
# Verify neuron info is the same in both objects
104105
assert metagraph_dict == subtensor_dict, (
105106
"Neuron info of Bob doesn't match b/w metagraph & subtensor"

0 commit comments

Comments
 (0)