Skip to content
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: adding RegisteredPayees to ics29 genesis state #1492

Merged
merged 16 commits into from
Jun 8, 2022

Conversation

damiannolan
Copy link
Member

@damiannolan damiannolan commented Jun 6, 2022

Description

  • Adding RegisteredPayees to ICS29 GenesisState

Needs: #1491
This PR includes the additions from the above and should be merged after the initial work in #1491

NOTE: this is one of many PRs to complete the feature work referenced in: #1477


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.

  • Targeted PR against correct branch (see CONTRIBUTING.md)
  • Linked to Github issue with discussion and accepted design OR link to spec that describes this work.
  • Code follows the module structure standards.
  • Wrote unit and integration tests
  • Updated relevant documentation (docs/) or specification (x/<module>/spec/)
  • Added relevant godoc comments.
  • Added a relevant changelog entry to the Unreleased section in CHANGELOG.md
  • Re-reviewed Files changed in the Github PR explorer
  • Review Codecov Report in the comment section below once CI passes

@codecov-commenter
Copy link

codecov-commenter commented Jun 6, 2022

Codecov Report

Merging #1492 (9e0cc43) into main (46f5eee) will decrease coverage by 0.03%.
The diff coverage is 91.50%.

Impacted file tree graph

@@            Coverage Diff             @@
##             main    #1492      +/-   ##
==========================================
- Coverage   80.36%   80.33%   -0.04%     
==========================================
  Files         166      166              
  Lines       12105    12238     +133     
==========================================
+ Hits         9728     9831     +103     
- Misses       1920     1946      +26     
- Partials      457      461       +4     
Impacted Files Coverage Δ
modules/apps/29-fee/types/genesis.go 81.96% <68.75%> (-2.82%) ⬇️
modules/apps/29-fee/keeper/keeper.go 92.48% <93.10%> (+0.09%) ⬆️
modules/apps/29-fee/types/msgs.go 90.75% <93.54%> (+0.98%) ⬆️
modules/apps/29-fee/keeper/genesis.go 87.50% <100.00%> (+2.50%) ⬆️
modules/apps/29-fee/keeper/msg_server.go 96.00% <100.00%> (+0.83%) ⬆️
modules/apps/29-fee/types/keys.go 97.14% <100.00%> (+0.47%) ⬆️
...ules/apps/27-interchain-accounts/types/metadata.go 83.50% <0.00%> (-9.60%) ⬇️
...7-interchain-accounts/controller/ibc_middleware.go 83.33% <0.00%> (-3.71%) ⬇️
modules/core/keeper/grpc_query.go 0.00% <0.00%> (ø)
...les/apps/27-interchain-accounts/host/ibc_module.go 100.00% <0.00%> (ø)
... and 3 more

@@ -77,5 +85,20 @@ func (gs GenesisState) Validate() error {
}
}

// Validate DistributionAddresses
for _, registeredDistAddr := range gs.RegisteredDistributionAddresses {
if _, err := sdk.AccAddressFromBech32(registeredDistAddr.Address); err != nil {
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

also for DistributionAddress

@damiannolan damiannolan changed the title feat: adding RegisteredDistributionAddresses to ics29 genesis state feat: adding RegisteredPayees to ics29 genesis state Jun 8, 2022
modules/apps/29-fee/keeper/keeper_test.go Outdated Show resolved Hide resolved
Comment on lines +20 to +23
repeated RegisteredPayee registered_payees = 3
[(gogoproto.moretags) = "yaml:\"registered_payees\"", (gogoproto.nullable) = false];
// list of registered relayer addresses
repeated RegisteredRelayerAddress registered_relayers = 3
repeated RegisteredRelayerAddress registered_relayers = 4
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why are there two of these? Shouldn't there be RegisteredPayees and RegisteredCounterpartyPayees?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yep, will be done in a follow up. Didn't want to mix the renaming of the counterparty address rpc with this!

Copy link
Contributor

@chatton chatton left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM nice work 🥇

@damiannolan damiannolan merged commit 57aa5ec into main Jun 8, 2022
@damiannolan damiannolan deleted the damian/1477-genesis-distaddrs branch June 8, 2022 15:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants