-
Notifications
You must be signed in to change notification settings - Fork 3.7k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
The default priority mechanism should be based on gas price rather than fee #12932
Comments
would you not need an oracle to get price of the asset? |
I mean the gas price specified in the tx, |
It's also a workaround for this issue: informalsystems/hermes#2350 |
I mean we can base it on gas price, but what does this buy us if the fee is based on the gas price? Also, the idea is that apps write their own priority AnteHandler.
Correct, but why is this a bad thing? Are you saying it's to give them equal/fair ranking? |
One concrete positivity is that the default setting won't break the IBC relayers, because currently they always set a static gas price, and they don't want their transactions to get reordered.
Yeah, it seems fairer to me, that's how ethereum has always been doing before EIP-1559. |
Ok, I don't see this as a problem actually. Makes sense. Wanna submit a quick PR @yihuang? :) |
Closes: cosmos#12932 gas price based priority is more intuitive and works better with ibc relayers.
sure, submitted. |
One thing to note is that by default transactions are not charged based on the gas used but by the specified fee. So the fee equals |
Summary of Bug
Currently the default priority mechanism is based on tx fee amount: https://github.com/cosmos/cosmos-sdk/blob/release/v0.46.x/x/auth/ante/validator_tx_fee.go#L54, I think it's more reasonable to based on price instead,
fee = price * gas limit
.Version
main and 0.46
Steps to Reproduce
The text was updated successfully, but these errors were encountered: