-
Notifications
You must be signed in to change notification settings - Fork 2.6k
AssetTxFeePaid
event should return fee and tip amounts in the asset ID
#12987
Comments
I think this is a reasonable change(I am not the one to make the decision here though). If this gets confirmed I will open a simple PR for this. |
Sounds reasonable as well to me! Please open a pr @Szegoo |
I realised that this is not as easy and simple to implement as I thought :P pub fn compute_actual_fee<Balance: FixedPointOperand + AtLeast32BitUnsigned>( So when we make a call to this from the let actual_fee = pallet_transaction_payment::Pallet::<T>::compute_actual_fee::<AssetBalanceOf<T>>(
len as u32, info, post_info, tip,
); This way we could make the I think the person who originally wrote the code was aware of this compromise and decided that it was not worth it. I am curious what you think about this @bkchr. |
Not sure I can follow you, don't we just need to add a substrate/frame/transaction-payment/asset-tx-payment/src/payment.rs Lines 153 to 155 in ea387c6
|
Correct, I overlooked that and started complicating 😅 |
Is there an existing issue?
Experiencing problems? Have you tried our Stack Exchange first?
Description of bug
When an
AssetTxFeePaid
event of the asset-tx-payment pallet is emitted, the fees and tip are subtracted from the asset ID balance of the sending account. However this event currently returns thetip
andactualFee
fields in balances of the chain native token. This is confusing for users and external tools, since they assume the values displayed in those fields are given in units of the asset ID.Steps to reproduce
Example screenshot of a transaction on Statemint paying the fees in the asset ID
1984
but emitting the AssetTxFeePaid event in DOT balances:The text was updated successfully, but these errors were encountered: