-
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
Add Fee granter field #7418
Add Fee granter field #7418
Conversation
Codecov Report
@@ Coverage Diff @@
## master #7418 +/- ##
==========================================
+ Coverage 55.23% 55.24% +0.01%
==========================================
Files 590 591 +1
Lines 36914 36932 +18
==========================================
+ Hits 20390 20404 +14
- Misses 14420 14422 +2
- Partials 2104 2106 +2 |
…ronc/fee-granter-field
…ronc/fee-granter-field
…ronc/fee-granter-field
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Nice one. I would just remove the ante decorator to simplify it
feeGranter := tx.FeeGranter() | ||
require.Empty(t, feeGranter) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
feeGranter := tx.FeeGranter() | |
require.Empty(t, feeGranter) | |
require.Empty(t, tx.FeeGranter()) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Good stuff
// RejectFeeGranterDecorator is a placeholder AnteDecorator for fee grants for | ||
// when that functionality is enabled. Currently it simpy rejects transactions | ||
// which have the Fee.granter field set. | ||
// RejectFeeGranterDecorator is an AnteDecorator which rejects transactions which |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
👍
Following up on https://github.com/cosmos/cosmos-sdk/pull/7384/files#r495258961, this adds the a
granter
field tocosmos.tx.v1beta1.Fee
in preparation for fee grants (#7106, #5768, #7074).For now, it just rejects transactions with
granter
set and serves as a placeholder for this functionality in the future.Adding the
granter
field now has the benefit of preventing spurious unknown field rejections for future protobuf clients which unnecessarily encode default values, as well as clearer error messages.Before we can merge this PR, please make sure that all the following items have been
checked off. If any of the checklist items are not applicable, please leave them but
write a little note why.
docs/
) or specification (x/<module>/spec/
)godoc
comments.Unreleased
section inCHANGELOG.md
Files changed
in the Github PR explorerCodecov Report
in the comment section below once CI passes