Skip to content

Commit fbc3c33

Browse files
fee updates from subtensor v3.2.4 (#58)
* wip * wip * wip
1 parent 1a04b83 commit fbc3c33

File tree

1 file changed

+33
-2
lines changed

1 file changed

+33
-2
lines changed

docs/fees.md

Lines changed: 33 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,8 @@ Many extrinsics in Bittensor are subject to a flat **weight-based fee**. In Polk
1818

1919
**Fee Details**:
2020
- **Current rate**: $\approx0.0013 \tau$
21-
- **Payment source**: Free balance of the transaction sender
22-
- **Denomination**: TAO
21+
- **Payment source**: Sender's TAO free balance by default. For specific extrinsics, if TAO is insufficient to cover fees, the chain will charge fees in Alpha instead (see "Smart Fee Payments (Alpha Fallback)" below).
22+
- **Denomination**: TAO by default. When fees are paid in Alpha, the TAO fee amount is converted to Alpha using the current Alpha price (no slippage).
2323
- **Impact on liquidity**: Fees are *recycled* (deducted from `TotalIssuance`)
2424
See: [Recycling and Burning](./glossary#recycling-and-burning)
2525

@@ -47,6 +47,11 @@ It is currently planned that the fee coefficient will be reduced to $0.005%$ (10
4747
- [`try_associate_hotkey`](https://github.com/opentensor/subtensor/blob/main/pallets/subtensor/src/macros/dispatches.rs#L1938)
4848
- [`schedule_swap_coldkey`](https://github.com/opentensor/subtensor/blob/main/pallets/subtensor/src/macros/dispatches.rs#L1333)
4949

50+
### Registration
51+
52+
- [`register`](https://github.com/opentensor/subtensor/blob/main/pallets/subtensor/src/macros/dispatches.rs#L895)
53+
- [`burned_register`](https://github.com/opentensor/subtensor/blob/main/pallets/subtensor/src/macros/dispatches.rs#L930)
54+
5055
### Subnet Management
5156

5257
- [`start_call`](https://github.com/opentensor/subtensor/blob/main/pallets/subtensor/src/macros/dispatches.rs#L1963)
@@ -88,6 +93,32 @@ It is currently planned that the fee coefficient will be reduced to $0.005%$ (10
8893

8994
</details>
9095

96+
## Alpha Fallback
97+
98+
For extrinsics that charge fees by swapping Alpha for TAO, if the sender's TAO balance cannot cover the weight-based transaction fee, the chain will fall back to charging the fee in Alpha. If both TAO and Alpha balances are insufficient to cover the anticipated fee, the transaction fails validation and will not be included in the mempool. When fees are paid in Alpha, the TAO fee is converted to Alpha using the current Alpha price with no slippage.
99+
100+
### Affected extrinsics
101+
102+
- `remove_stake`
103+
- `remove_stake_limit`
104+
- `remove_stake_full_limit`
105+
- `unstake_all`
106+
- `unstake_all_alpha`
107+
- `move_stake`
108+
- `transfer_stake`
109+
- `swap_stake`
110+
- `swap_stake_limit`
111+
- `recycle_alpha`
112+
- `burn_alpha`
113+
114+
### Complete unstaking handling
115+
116+
For `remove_stake`, `remove_stake_limit`, `recycle_alpha`, and `burn_alpha`: after withdrawing Alpha fees, if the remaining Alpha balance is too small to keep as a dust balance, the transaction will consume and process the entire remaining Alpha balance in the same call.
117+
118+
### Updated handling of `NotEnoughStakeToWithdraw`
119+
120+
For `remove_stake`, `remove_stake_limit`, `recycle_alpha`, and `burn_alpha`: if the requested amount exceeds the available Alpha, the amount is capped at the available Alpha and the extrinsic succeeds (assuming no other errors).
121+
91122
## Swap Fees for Stake and Unstake Operations
92123

93124
In addition to the weight-based fee above, staking and unstaking operations are subject to fees based on a percentage of the quantity of transacted liquidity.

0 commit comments

Comments
 (0)