-
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
feat!: Add bech32 prefix to authkeeper #9759
Conversation
Codecov Report
@@ Coverage Diff @@
## master #9759 +/- ##
==========================================
- Coverage 63.75% 63.74% -0.01%
==========================================
Files 566 567 +1
Lines 53402 53422 +20
==========================================
+ Hits 34048 34056 +8
- Misses 17435 17445 +10
- Partials 1919 1921 +2
|
c71015f
to
c78a879
Compare
Visit https://dashboard.github.orijtech.com?pr=9759&repo=cosmos%2Fcosmos-sdk to see benchmark details. |
c78a879
to
7da481f
Compare
7da481f
to
556810d
Compare
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.
looks like a good start. I'm not sure the proto field names are perfect, but can't think of anything else for now
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.
Looks good overall, just left a couple comments
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Actually we still do it! We just use the global config for now, let's tackle that in a separate PR (added an item in #9690). See https://github.com/cosmos/cosmos-sdk/pull/9759/files#diff-c73f18717271f4171c3ae22f928c5ab7b9890185a9101828252dacab71e78545R31 |
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.
lgtm overall, small nits around not exporting too many public methods
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
@AmauryM I addressed your comments, can you take one more look, please? |
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.
came up with some new comments while re-reviewing
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
Co-authored-by: Amaury <1293565+amaurym@users.noreply.github.com>
ab34ebf
to
16f55fc
Compare
16f55fc
to
fb9e5a3
Compare
<!-- The default pull request template is for types feat, fix, or refactor. For other templates, add one of the following parameters to the url: - template=docs.md - template=other.md --> ## Description Closes **Step1** from cosmos#9690 <!-- Add a description of the changes that this PR introduces and the files that are the most critical to review. --> - Add auth keeper methods and gRPC queries: - the `NewAccountKeeper` should take a `string bech32Prefix` argument - ` auth AccountKeeper` implements `Codec` interface that contains 2 methods: `ConvertAddressStringToBytes` and `ConvertAddressBytesToString` - Add the 3 following gRPC queries: - Get bech32 prefix - `AddressStringToBytes` (converts `AccountAddr` string to `AccountAddr` bytes) - `AddressBytesToString` ( converts `AccountAddr` bytes to `AccountAddr` str) - Add the corresponding keeper methods - Add tests --- ### Author Checklist *All items are required. Please add a note to the item if the item is not applicable and please add links to any relevant follow up issues.* I have... - [ ] included the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] added `!` to the type prefix if API or client breaking change - [ ] targeted the correct branch (see [PR Targeting](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#pr-targeting)) - [ ] provided a link to the relevant issue or specification - [ ] followed the guidelines for [building modules](https://github.com/cosmos/cosmos-sdk/blob/master/docs/building-modules) - [x] included the necessary unit and integration [tests](https://github.com/cosmos/cosmos-sdk/blob/master/CONTRIBUTING.md#testing) - [x] added a changelog entry to `CHANGELOG.md` - [x] included comments for [documenting Go code](https://blog.golang.org/godoc) - [ ] updated the relevant documentation or specification - [x] reviewed "Files changed" and left comments if necessary - [ ] confirmed all CI checks have passed ### Reviewers Checklist *All items are required. Please add a note if the item is not applicable and please add your handle next to the items reviewed if you only reviewed selected items.* I have... - [ ] confirmed the correct [type prefix](https://github.com/commitizen/conventional-commit-types/blob/v3.0.0/index.json) in the PR title - [ ] confirmed `!` in the type prefix if API or client breaking change - [ ] confirmed all author checklist items have been addressed - [ ] reviewed state machine logic - [ ] reviewed API design and naming - [ ] reviewed documentation is accurate - [ ] reviewed tests and test coverage - [ ] manually tested (if applicable)
Description
Closes Step1 from #9690
NewAccountKeeper
should take astring bech32Prefix
argumentauth AccountKeeper
implementsCodec
interface that contains 2 methods:ConvertAddressStringToBytes
andConvertAddressBytesToString
AddressStringToBytes
(convertsAccountAddr
string toAccountAddr
bytes)AddressBytesToString
( convertsAccountAddr
bytes toAccountAddr
str)Author Checklist
All items are required. Please add a note to the item if the item is not applicable and
please add links to any relevant follow up issues.
I have...
!
to the type prefix if API or client breaking changeCHANGELOG.md
Reviewers Checklist
All items are required. Please add a note if the item is not applicable and please add
your handle next to the items reviewed if you only reviewed selected items.
I have...
!
in the type prefix if API or client breaking change