Skip to content

Commit 3c15308

Browse files
author
Roman
committed
remove ownership check
1 parent 79e6639 commit 3c15308

File tree

2 files changed

+0
-32
lines changed

2 files changed

+0
-32
lines changed

bittensor/core/extrinsics/asyncex/move_stake.py

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -71,14 +71,6 @@ async def transfer_stake_extrinsic(
7171
"""
7272

7373
amount.set_unit(netuid=origin_netuid)
74-
# Verify ownership
75-
hotkey_owner = await subtensor.get_hotkey_owner(hotkey_ss58)
76-
if hotkey_owner != wallet.coldkeypub.ss58_address:
77-
logging.error(
78-
f":cross_mark: [red]Failed[/red]: Hotkey: {hotkey_ss58} does not belong to the origin coldkey owner: "
79-
f"{wallet.coldkeypub.ss58_address}"
80-
)
81-
return False
8274

8375
# Check sufficient stake
8476
stake_in_origin, stake_in_destination = await _get_stake_in_origin_and_dest(
@@ -194,14 +186,6 @@ async def swap_stake_extrinsic(
194186
bool: True if the swap was successful, False otherwise.
195187
"""
196188
amount.set_unit(netuid=origin_netuid)
197-
# Verify ownership
198-
hotkey_owner = await subtensor.get_hotkey_owner(hotkey_ss58)
199-
if hotkey_owner != wallet.coldkeypub.ss58_address:
200-
logging.error(
201-
f":cross_mark: [red]Failed[/red]: Hotkey: {hotkey_ss58} does not belong to the origin coldkey owner: "
202-
f"{wallet.coldkeypub.ss58_address}"
203-
)
204-
return False
205189

206190
# Check sufficient stake
207191
stake_in_origin, stake_in_destination = await _get_stake_in_origin_and_dest(

bittensor/core/extrinsics/move_stake.py

Lines changed: 0 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -68,14 +68,6 @@ def transfer_stake_extrinsic(
6868
"""
6969

7070
amount.set_unit(netuid=origin_netuid)
71-
# Verify ownership
72-
hotkey_owner = subtensor.get_hotkey_owner(hotkey_ss58)
73-
if hotkey_owner != wallet.coldkeypub.ss58_address:
74-
logging.error(
75-
f":cross_mark: [red]Failed[/red]: Hotkey: {hotkey_ss58} does not belong to the origin coldkey owner: "
76-
f"{wallet.coldkeypub.ss58_address}"
77-
)
78-
return False
7971

8072
# Check sufficient stake
8173
stake_in_origin, stake_in_destination = _get_stake_in_origin_and_dest(
@@ -192,14 +184,6 @@ def swap_stake_extrinsic(
192184
"""
193185

194186
amount.set_unit(netuid=origin_netuid)
195-
# Verify ownership
196-
hotkey_owner = subtensor.get_hotkey_owner(hotkey_ss58)
197-
if hotkey_owner != wallet.coldkeypub.ss58_address:
198-
logging.error(
199-
f":cross_mark: [red]Failed[/red]: Hotkey: {hotkey_ss58} does not belong to the origin coldkey owner: "
200-
f"{wallet.coldkeypub.ss58_address}"
201-
)
202-
return False
203187

204188
# Check sufficient stake
205189
stake_in_origin, stake_in_destination = _get_stake_in_origin_and_dest(

0 commit comments

Comments
 (0)