-
Notifications
You must be signed in to change notification settings - Fork 3.6k
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
ibc/03-connection: import export GenesisState #6067
Conversation
@@ -72,6 +83,12 @@ func (c ConnectionEnd) ValidateBasic() error { | |||
return sdkerrors.Wrap(ibctypes.ErrInvalidVersion, "version can't be blank") | |||
} | |||
} | |||
if c.ID == c.Counterparty.ConnectionID { |
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.
I added these 2 extra validations @cwgoes
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.
Why? It's fine if the identifiers are the same.
Codecov Report
@@ Coverage Diff @@
## master #6067 +/- ##
==========================================
- Coverage 54.64% 54.35% -0.29%
==========================================
Files 426 430 +4
Lines 25890 26107 +217
==========================================
+ Hits 14148 14191 +43
- Misses 10763 10937 +174
Partials 979 979 |
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.
Import/export bits look fine but I don't think the additional validation is necessary.
@@ -72,6 +83,12 @@ func (c ConnectionEnd) ValidateBasic() error { | |||
return sdkerrors.Wrap(ibctypes.ErrInvalidVersion, "version can't be blank") | |||
} | |||
} | |||
if c.ID == c.Counterparty.ConnectionID { |
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.
Why? It's fine if the identifiers are the same.
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.
Changes look pretty straightforward to me. I can't speak to the actual validation business logic.
…cosmos-sdk into fedekunze/import-export-ibc-pt-1
ref: #5948
Description
For contributor use:
docs/
) or specification (x/<module>/spec/
)godoc
comments.Unreleased
section inCHANGELOG.md
Files changed
in the Github PR explorerFor admin use:
WIP
,R4R
,docs
, etc)