bittensor.core.extrinsics.asyncex.unstaking#
Functions#
| 
 | Removes stake into the wallet coldkey from the specified hotkey  | 
| 
 | Removes stake from each  | 
Module Contents#
- async bittensor.core.extrinsics.asyncex.unstaking.unstake_extrinsic(subtensor, wallet, hotkey_ss58=None, netuid=None, amount=None, wait_for_inclusion=True, wait_for_finalization=False)#
- Removes stake into the wallet coldkey from the specified hotkey - uid.- Parameters:
- subtensor (bittensor.core.async_subtensor.AsyncSubtensor) – AsyncSubtensor instance. 
- wallet (bittensor_wallet.Wallet) – Bittensor wallet object. 
- hotkey_ss58 (Optional[str]) – The - ss58address of the hotkey to unstake from. By default, the wallet hotkey is used.
- netuid (Optional[int]) – The subnet uid to unstake from. 
- amount (Union[Balance, float]) – Amount to stake as Bittensor balance, or - floatinterpreted as Tao.
- wait_for_inclusion (bool) – If set, waits for the extrinsic to enter a block before returning - True, or returns- Falseif the extrinsic fails to enter the block within the timeout.
- wait_for_finalization (bool) – If set, waits for the extrinsic to be finalized on the chain before returning - True, or returns- Falseif the extrinsic fails to be finalized within the timeout.
 
- Returns:
- Flag is Trueif extrinsic was finalized or included in the block. If we did not wait for
- finalization / inclusion, the response is - True.
 
- Flag is 
- Return type:
- success (bool) 
 
- async bittensor.core.extrinsics.asyncex.unstaking.unstake_multiple_extrinsic(subtensor, wallet, hotkey_ss58s, netuids, amounts=None, wait_for_inclusion=True, wait_for_finalization=False)#
- Removes stake from each - hotkey_ss58in the list, using each amount, to a common coldkey.- Parameters:
- subtensor (bittensor.core.subtensor.Subtensor) – Subtensor instance. 
- wallet (bittensor_wallet.Wallet) – The wallet with the coldkey to unstake to. 
- hotkey_ss58s (List[str]) – List of hotkeys to unstake from. 
- netuids (List[int]) – List of netuids to unstake from. 
- amounts (List[Union[Balance, float]]) – List of amounts to unstake. If - None, unstake all.
- wait_for_inclusion (bool) – If set, waits for the extrinsic to enter a block before returning - True, or returns- Falseif the extrinsic fails to enter the block within the timeout.
- wait_for_finalization (bool) – If set, waits for the extrinsic to be finalized on the chain before returning - True, or returns- Falseif the extrinsic fails to be finalized within the timeout.
 
- Returns:
- Flag is Trueif extrinsic was finalized or included in the block. Flag isTrueif any
- wallet was unstaked. If we did not wait for finalization / inclusion, the response is - True.
 
- Flag is 
- Return type:
- success (bool)