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(x/ecocredit)!: gov approved bridge chains #1462

Merged
merged 16 commits into from
Sep 3, 2022

Conversation

technicallyty
Copy link
Contributor

@technicallyty technicallyty commented Sep 1, 2022

Description

  • adds a new governance table AllowedBridgeChains
  • adds gov tx's AddAllowedBridgeChain and RemoveAllowedBridgeChain
  • adds query methods for AllowedBridgeChains table
  • adds CLI cmd for querying the allowed chains
  • updates tests to reflect new requirement for bridging operations
  • add polygon to the initial state for ecocredit migration.

I assume the bridge service will be live and running by the next upgrade, so went ahead and initialized the table with POLYGON in the migration. If thats not a correct assumption, I will remove it

Closes: #1119


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 in the PR title
  • added ! to the type prefix if API or client breaking change
  • targeted the correct branch (see PR Targeting)
  • provided a link to the relevant issue or specification
  • followed the guidelines for building modules
  • included the necessary unit and integration tests
  • added a changelog entry to CHANGELOG.md
  • included comments for documenting Go code
  • updated the relevant documentation or specification
  • 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 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)

@technicallyty technicallyty marked this pull request as ready for review September 1, 2022 20:58
@technicallyty technicallyty requested a review from a team September 1, 2022 20:58
Copy link
Member

@ryanchristo ryanchristo left a comment

Choose a reason for hiding this comment

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

Nice work! This looks great. A couple questions/suggestions. Will manually test.

proto/regen/ecocredit/v1/state.proto Outdated Show resolved Hide resolved
x/ecocredit/base/keeper/query_params_test.go Outdated Show resolved Hide resolved
x/ecocredit/server/migrations.go Outdated Show resolved Hide resolved
@codecov
Copy link

codecov bot commented Sep 2, 2022

Codecov Report

Merging #1462 (33f0c4b) into main (674b624) will decrease coverage by 0.20%.
The diff coverage is 47.93%.

@@            Coverage Diff             @@
##             main    #1462      +/-   ##
==========================================
- Coverage   78.42%   78.21%   -0.21%     
==========================================
  Files         238      243       +5     
  Lines       18513    18626     +113     
==========================================
+ Hits        14518    14568      +50     
- Misses       3150     3206      +56     
- Partials      845      852       +7     
Impacted Files Coverage Δ
x/ecocredit/base/client/query.go 66.73% <0.00%> (-2.22%) ⬇️
...edit/base/types/v1/msg_add_allowed_bridge_chain.go 0.00% <0.00%> (ø)
x/ecocredit/base/types/v1/msg_bridge.go 80.55% <ø> (-1.50%) ⬇️
x/ecocredit/base/utils.go 85.59% <ø> (ø)
x/ecocredit/client/query.go 0.00% <0.00%> (ø)
x/ecocredit/server/migrations.go 31.25% <0.00%> (-10.42%) ⬇️
...t/base/types/v1/msg_remove_allowed_bridge_chain.go 53.33% <53.33%> (ø)
...ocredit/base/keeper/query_allowed_bridge_chains.go 60.00% <60.00%> (ø)
x/ecocredit/base/keeper/query_params.go 56.00% <60.00%> (+0.26%) ⬆️
x/ecocredit/base/keeper/msg_bridge_receive.go 77.03% <62.50%> (-1.09%) ⬇️
... and 5 more

@technicallyty technicallyty changed the title feat(x/ecocredit): gov approved bridge chains feat(x/ecocredit)!: gov approved bridge chains Sep 2, 2022
Copy link
Member

@ryanchristo ryanchristo left a comment

Choose a reason for hiding this comment

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

@ryanchristo ryanchristo merged commit 2da88f6 into main Sep 3, 2022
@ryanchristo ryanchristo deleted the ty/1119-gov_approved_bridge_chains branch September 3, 2022 00:53
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.

Governance gated chains for bridging credits
3 participants