Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
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
Consolidate usage of NewErrorAcknowledgement #1565
Consolidate usage of NewErrorAcknowledgement #1565
Changes from 17 commits
c264fa0
1ad5de5
e49b35f
8283fbe
2fd3b3a
38c89eb
2102783
a5d118e
647d1e1
0cd0af3
ea311bd
8e5eb6e
725ef86
52ede1a
e0a953f
c480718
d1089b9
230a219
6c15291
84d2d44
d3e72ea
50dfd89
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
nit: format imports
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.
Should we be creating an SDK error with a code here?
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.
e.g. https://github.com/cosmos/ibc-go/blob/main/modules/apps/transfer/keeper/relay.go#L76
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.
We're getting the error code here and adding it to the string. AFAIK we need to do it this way for determinism?
https://github.com/cosmos/ibc-go/pull/1565/files#diff-7a038c27f47c6c3093e19a350a851ccbc15c5ef7036060e3c631a73579acc333R35
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.
in this particular case the only thing that actually matters is if the error is nil or not, but we use the sdkerrors.Wrap to create this error for consistency.
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 think we should use
icatypes.ErrInvalidChannelFlow
.See: https://github.com/cosmos/ibc-go/blob/main/modules/apps/27-interchain-accounts/controller/ibc_middleware.go#L79
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.
for now I duplicated controller/keeper/events.go to avoid calling into a different keeper package and also to not break current conventions.
This file was deleted.
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.
ditto
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 like this!
This file was deleted.
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.
Should we keep one of these two
TestAcknowledgementError
tests and move it to04-channel
?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.
Yes, I think the
TestABCICodeDeterminism
test should also be moved to04-channel
, its duplicated both above here and in ICA tests