Skip to content

Commit b78498c

Browse files
edit docstrings
1 parent 3e7cc71 commit b78498c

File tree

1 file changed

+28
-28
lines changed

1 file changed

+28
-28
lines changed

bittensor/core/async_subtensor.py

Lines changed: 28 additions & 28 deletions
Original file line numberDiff line numberDiff line change
@@ -1856,7 +1856,7 @@ async def get_delegates(
18561856
Arguments:
18571857
block: The blockchain block number for the query.
18581858
block_hash: hash of the blockchain block number for the query.
1859-
reuse_block (Optional[bool]): whether to reuse the last-used block hash.
1859+
reuse_block: whether to reuse the last-used block hash.
18601860
18611861
Returns:
18621862
List of DelegateInfo objects, or an empty list if there are no delegates.
@@ -2094,7 +2094,7 @@ async def get_netuids_for_hotkey(
20942094
hotkey_ss58: The `SS58` address of the neuron's hotkey.
20952095
block: The blockchain block number for the query.
20962096
block_hash: The hash of the blockchain block number at which to perform the query.
2097-
reuse_block (Optional[bool]): Whether to reuse the last-used block hash when retrieving info.
2097+
reuse_block: Whether to reuse the last-used block hash when retrieving info.
20982098
20992099
Returns:
21002100
A list of netuids where the neuron is a member.
@@ -2455,8 +2455,8 @@ async def get_owned_hotkeys(
24552455
Retrieves all hotkeys owned by a specific coldkey address.
24562456
24572457
Arguments:
2458-
coldkey_ss58 (str): The SS58 address of the coldkey to query.
2459-
block (int): The blockchain block number for the query.
2458+
coldkey_ss58: The SS58 address of the coldkey to query.
2459+
block: The blockchain block number for the query.
24602460
block_hash: The hash of the blockchain block number for the query.
24612461
reuse_block: Whether to reuse the last-used blockchain block hash.
24622462
@@ -2488,7 +2488,7 @@ async def get_stake(
24882488
24892489
Arguments:
24902490
hotkey_ss58: The SS58 address of the hotkey.
2491-
coldkey_ss58 (str): The SS58 address of the coldkey.
2491+
coldkey_ss58: The SS58 address of the coldkey.
24922492
netuid: The subnet ID.
24932493
block: The block number at which to query the stake information.
24942494
block_hash: The hash of the block to retrieve the stake from. Do not specify if using block
@@ -2646,7 +2646,7 @@ async def get_subnet_prices(
26462646
) -> dict[int, Balance]:
26472647
"""Gets the current Alpha price in TAO for a specified subnet.
26482648
2649-
Args:
2649+
Argsuments:
26502650
block: The blockchain block number for the query.
26512651
block_hash: The hash of the block to retrieve the stake from. Do not specify if using block
26522652
or reuse_block
@@ -2768,9 +2768,9 @@ async def get_stake_for_coldkey_and_hotkey(
27682768
Retrieves all coldkey-hotkey pairing stake across specified (or all) subnets
27692769
27702770
Arguments:
2771-
coldkey_ss58 (str): The SS58 address of the coldkey.
2771+
coldkey_ss58: The SS58 address of the coldkey.
27722772
hotkey_ss58: The SS58 address of the hotkey.
2773-
netuids (Optional[list[int]]): The subnet IDs to query for. Set to `None` for all subnets.
2773+
netuids: The subnet IDs to query for. Set to `None` for all subnets.
27742774
block: The block number at which to query the stake information.
27752775
block_hash: The hash of the block to retrieve the stake from. Do not specify if using block
27762776
or reuse_block
@@ -2815,7 +2815,7 @@ async def get_stake_for_coldkey(
28152815
Retrieves the stake information for a given coldkey.
28162816
28172817
Arguments:
2818-
coldkey_ss58 (str): The SS58 address of the coldkey.
2818+
coldkey_ss58: The SS58 address of the coldkey.
28192819
block: The block number at which to query the stake information.
28202820
block_hash: The hash of the blockchain block number for the query.
28212821
reuse_block: Whether to reuse the last-used block hash.
@@ -2923,7 +2923,7 @@ async def get_subnet_hyperparameters(
29232923
netuid: The network UID of the subnet to query.
29242924
block: The blockchain block number for the query.
29252925
block_hash: The hash of the blockchain block number for the query.
2926-
reuse_blocko reuse the last-used blockchain hash.
2926+
reuse_block: Whether to reuse the last-used blockchain hash.
29272927
29282928
Returns:
29292929
The subnet's hyperparameters, or `None` if not available.
@@ -3070,7 +3070,7 @@ async def get_vote_data(
30703070
about how senate members have voted on the proposal.
30713071
30723072
Arguments:
3073-
proposal_hash (str): The hash of the proposal for which voting data is requested.
3073+
proposal_hash: The hash of the proposal for which voting data is requested.
30743074
block: The blockchain block number for the query.
30753075
block_hash: The hash of the blockchain block number to query the voting data.
30763076
reuse_block: Whether to reuse the last-used blockchain block hash.
@@ -3142,9 +3142,9 @@ async def filter_netuids_by_registered_hotkeys(
31423142
Filters a given list of all netuids for certain specified netuids and hotkeys
31433143
31443144
Arguments:
3145-
all_netuids (Iterable[int]): A list of netuids to filter.
3146-
filter_for_netuids (Iterable[int]): A subset of all_netuids to filter from the main list.
3147-
all_hotkeys (Iterable[Wallet]): Hotkeys to filter from the main list.
3145+
all_netuids: A list of netuids to filter.
3146+
filter_for_netuids: A subset of all_netuids to filter from the main list.
3147+
all_hotkeys: Hotkeys to filter from the main list.
31483148
block: The blockchain block number for the query.
31493149
block_hash: hash of the blockchain block number at which to perform the query.
31503150
reuse_block: whether to reuse the last-used blockchain hash when retrieving info.
@@ -3241,7 +3241,7 @@ async def is_hotkey_delegate(
32413241
hotkey_ss58: The SS58 address of the neuron's hotkey.
32423242
block: The blockchain block number for the query.
32433243
block_hash: The hash of the blockchain block number for the query.
3244-
reuse_block (Optional[bool]): Whether to reuse the last-used block hash.
3244+
reuse_block: Whether to reuse the last-used block hash.
32453245
32463246
Returns:
32473247
`True` if the hotkey is a delegate, `False` otherwise.
@@ -3926,7 +3926,7 @@ async def weights(
39263926
netuid: The network UID of the subnet to query.
39273927
block: Block number for synchronization, or `None` for the latest block.
39283928
block_hash: The hash of the blockchain block for the query.
3929-
reuse_blocko reuse the last-used blockchain block hash.
3929+
reuse_block: reuse the last-used blockchain block hash.
39303930
39313931
Returns:
39323932
A list of tuples mapping each neuron's UID to its assigned weights.
@@ -4778,12 +4778,12 @@ async def root_register(
47784778
Register neuron by recycling some TAO.
47794779
47804780
Arguments:
4781-
wallet (bittensor_wallet.Wallet): Bittensor wallet instance.
4781+
wallet: Bittensor wallet instance.
47824782
block_hash: This argument will be removed in Bittensor v10
4783-
wait_for_inclusion (bool): Waits for the transaction to be included in a block. Default is ``False``.
4784-
wait_for_finalization (bool): Waits for the transaction to be finalized on the blockchain. Default is
4785-
``False``.
4786-
period (Optional[int]): The number of blocks during which the transaction will remain valid after it's
4783+
wait_for_inclusion: Waits for the transaction to be included in a block. Default is `False`.
4784+
wait_for_finalization: Waits for the transaction to be finalized on the blockchain. Default is
4785+
`False`.
4786+
period: The number of blocks during which the transaction will remain valid after it's
47874787
submitted. If the transaction is not included in a block within that number of blocks, it will expire
47884788
and be rejected. You can think of it as an expiration date for the transaction.
47894789
@@ -4993,7 +4993,7 @@ async def set_subnet_identity(
49934993
Arguments:
49944994
wallet: The wallet instance that will authorize the transaction.
49954995
netuid: The unique ID of the network on which the operation takes place.
4996-
subnet_identity (SubnetIdentity): The identity data of the subnet including attributes like name, GitHub
4996+
subnet_identity: The identity data of the subnet including attributes like name, GitHub
49974997
repository, contact, URL, discord, description, and any additional metadata.
49984998
wait_for_inclusion: Indicates if the function should wait for the transaction to be included in the
49994999
block.
@@ -5163,7 +5163,7 @@ async def serve_axon(
51635163
51645164
Arguments:
51655165
netuid: The unique identifier of the subnetwork.
5166-
axon (bittensor.core.axon.Axon): The Axon instance to be registered for serving.
5166+
axon: The Axon instance to be registered for serving.
51675167
wait_for_inclusion: Waits for the transaction to be included in a block. Default is `False`.
51685168
wait_for_finalization: Waits for the transaction to be finalized on the blockchain. Default is
51695169
`True`.
@@ -5384,7 +5384,7 @@ async def transfer_stake(
53845384
53855385
Arguments:
53865386
wallet: The wallet to transfer stake from.
5387-
destination_coldkey_ss58 (str): The destination coldkey SS58 address.
5387+
destination_coldkey_ss58: The destination coldkey SS58 address.
53885388
hotkey_ss58: The hotkey SS58 address associated with the stake.
53895389
origin_netuid: The source subnet UID.
53905390
destination_netuid: The destination subnet UID.
@@ -5574,10 +5574,10 @@ async def unstake_multiple(
55745574
Arguments:
55755575
wallet: The wallet linked to the coldkey from which the stakes are being
55765576
withdrawn.
5577-
s (List[str]): A list of hotkey `SS58` addresses to unstake from.
5578-
netuidst]): Subnets unique IDs.
5579-
amounts (List[Union[Balance, float]]): The amounts of TAO to unstake from each hotkey. If not provided,
5580-
unstakes all_inclusion (bool): Waits for the transaction to be included in a block.
5577+
hotkey_ss58s: A list of hotkey `SS58` addresses to unstake from.
5578+
netuids: Subnets unique IDs.
5579+
amounts: The amounts of TAO to unstake from each hotkey. If not provided, unstakes all.
5580+
wait_for_inclusion: Waits for the transaction to be included in a block.
55815581
wait_for_finalization: Waits for the transaction to be finalized on the blockchain.
55825582
period: The number of blocks during which the transaction will remain valid after it's
55835583
submitted. If the transaction is not included in a block within that number of blocks, it will expire

0 commit comments

Comments
 (0)