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

chore: adding MsgChannelUpgradeTimeout fields and sdk.Msg interface impl #1830

Merged

Conversation

damiannolan
Copy link
Member

Description

  • Adding fields to MsgChannelUpgradeTimeout
  • Implement ValidateBasic and GetSigners methods for sdk.Msg interface
  • Adding tests

closes: #1626


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

Comment on lines +612 to +614
if msg.CounterpartyChannel.State != OPEN {
return sdkerrors.Wrapf(ErrInvalidChannelState, "expected: %s, got: %s", OPEN, msg.CounterpartyChannel.State)
}
Copy link
Member Author

Choose a reason for hiding this comment

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

@AdityaSripal do you think there's any additional checks we need to perform on the counterparty channel?
Maybe check the channel version is not empty?

return sdkerrors.Wrap(sdkerrors.ErrInvalidHeight, "proof height must be non-zero")
}

if msg.CounterpartyChannel.State != OPEN {
Copy link
Contributor

Choose a reason for hiding this comment

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

could the counterparty channel state be in INITUPGRADE (crossing hellos?)

Copy link
Member Author

Choose a reason for hiding this comment

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

As far as I know crossing hellos are no longer supported, and won't be for channel upgrades?
cc. @AdityaSripal

Copy link
Contributor

@charleenfei charleenfei left a comment

Choose a reason for hiding this comment

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

tentative approval if we don't support crossing hellos anymore

@damiannolan
Copy link
Member Author

tentative approval if we don't support crossing hellos anymore

I'm going to merge this. We can follow up with @AdityaSripal about this later 👍

@damiannolan damiannolan enabled auto-merge (squash) August 5, 2022 11:09
@damiannolan damiannolan enabled auto-merge (squash) August 5, 2022 11:49
@damiannolan damiannolan merged commit 0fed3d0 into 04-channel-upgrades Aug 5, 2022
@damiannolan damiannolan deleted the damian/1626-impl-sdk-msg-upgrade-timeout branch August 5, 2022 13:24
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.

3 participants