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: add intertx module #1477

Merged
merged 36 commits into from
Nov 2, 2022
Merged

feat: add intertx module #1477

merged 36 commits into from
Nov 2, 2022

Conversation

technicallyty
Copy link
Contributor

Description

adds the intertx module

Closes: #1453


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)

@codecov
Copy link

codecov bot commented Sep 7, 2022

Codecov Report

Merging #1477 (a59ae46) into main (01e2a6a) will decrease coverage by 1.15%.
The diff coverage is 25.67%.

❗ Current head a59ae46 differs from pull request most recent head 4757b0f. Consider uploading reports for the commit 4757b0f to get more accurate results

Additional details and impacted files
@@            Coverage Diff             @@
##             main    #1477      +/-   ##
==========================================
- Coverage   78.72%   77.56%   -1.16%     
==========================================
  Files         251      263      +12     
  Lines       18849    19244     +395     
==========================================
+ Hits        14838    14926      +88     
- Misses       3149     3453     +304     
- Partials      862      865       +3     
Impacted Files Coverage Δ
app/upgrades/v5/upgrade.go 78.12% <ø> (ø)
x/intertx/client/query.go 0.00% <0.00%> (ø)
x/intertx/client/tx.go 0.00% <0.00%> (ø)
x/intertx/keeper/msg_register_account.go 0.00% <0.00%> (ø)
x/intertx/keeper/msg_submit_tx.go 0.00% <0.00%> (ø)
x/intertx/keeper/query_interchain_account.go 0.00% <0.00%> (ø)
x/intertx/types/v1/msg_register_account.go 0.00% <0.00%> (ø)
x/intertx/types/v1/msg_submit_tx.go 0.00% <0.00%> (ø)
x/intertx/module/ibc_module.go 14.28% <14.28%> (ø)
x/intertx/keeper/keeper.go 60.00% <60.00%> (ø)
... and 19 more

@technicallyty technicallyty marked this pull request as ready for review October 25, 2022 07:08
@technicallyty technicallyty requested a review from a team October 25, 2022 07:08
@@ -0,0 +1,53 @@
Feature: MsgRegisterAccount
Copy link
Contributor

Choose a reason for hiding this comment

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

would be nice to have a test case for amino sign bytes.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

added for MsgRegisterAccount e074640

dont think its possible for MsgSubmitTx though, since it contains protobuf.Any

Copy link
Contributor

Choose a reason for hiding this comment

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

The MsgSubmitTx's GetSignBytes method panicking because, we need to register intertx codec with every other modules RegisterLegacyAmino method. We had a similar issue with SDK's governance module MsgSubmitProposal 13196.

Copy link
Contributor Author

@technicallyty technicallyty Oct 26, 2022

Choose a reason for hiding this comment

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

oof, that makes it impossible to use via amino right? that doesn't seem very good...

Copy link
Contributor

@aleem1314 aleem1314 Oct 27, 2022

Choose a reason for hiding this comment

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

Not sure if this will work. We can import all modules RegisterLegacyAminoCodec() method and register with intertx module codec.

app/app.go Outdated Show resolved Hide resolved
x/intertx/client/tx.go Outdated Show resolved Hide resolved
x/intertx/go.mod Outdated Show resolved Hide resolved
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.

Looking good. Will need to figure out how to manually test. A few minor comments.

app/app.go Show resolved Hide resolved
x/intertx/module/module.go Outdated Show resolved Hide resolved
x/intertx/types/v1/features/msg_submit_tx.feature Outdated Show resolved Hide resolved
Copy link
Contributor

@aleem1314 aleem1314 left a comment

Choose a reason for hiding this comment

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

Looking good. A few comments and a CHANGELOG entry.

Copy link
Contributor

@aleem1314 aleem1314 left a comment

Choose a reason for hiding this comment

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

lgtm

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.

Looking good. Gave it a more thorough review and attempted some basic CLI testing.

x/intertx/client/tx.go Outdated Show resolved Hide resolved
x/intertx/client/tx.go Outdated Show resolved Hide resolved
x/intertx/keeper/msg_register_account.go Show resolved Hide resolved
x/intertx/client/query.go Outdated Show resolved Hide resolved
x/intertx/types/v1/msg_register_account_test.go Outdated Show resolved Hide resolved
x/intertx/types/v1/codec.go Outdated Show resolved Hide resolved
x/intertx/types/v1/codec.go Outdated Show resolved Hide resolved
x/intertx/module/module.go Show resolved Hide resolved
x/intertx/types/v1/msg_submit_tx.go Show resolved Hide resolved
go.mod Outdated Show resolved Hide resolved
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.

tACK / utACK

Tested commands are implemented correctly and return expected errors. We will need to figure out the best means for manual testing (item included in v5.0 readiness checklist).

Nice work! Thanks for taking this on.

@ryanchristo ryanchristo merged commit 22beb86 into main Nov 2, 2022
@ryanchristo ryanchristo deleted the ty/1453-ICA_Controller branch November 2, 2022 23:03
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.

Wire up ICA Controller
3 participants