-
Notifications
You must be signed in to change notification settings - Fork 1.7k
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
Properly handle timeouts and packet sequence numbers on ORDERED
channels
#663
Conversation
…stin/ordered-timeouts
…stin/ordered-timeouts
This PR has been tested using the interchain accounts demo here To test with this branch checkout commit hash b92f1de and You should see a interchain account successfully registered, a packet successfully relayed and then a successfully timed out packet. Not an ideal way to test this but I had started adding these test cases to the IBC-test-framework and then fudged my branch so will have to reimplement this there. |
ordered
channelsORDERED
channels
ORDERED
channelsORDERED
channels
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 skimmed through the change this morning and everything looks correct AFAICS.
Addressed the few suggestions, this should be gtm. |
SHIPPING |
Currently we do not differentiate between
ORDERED
andUNORDERED
channels when handling timeouts in the relayer.ORDERED
channels require a proof ofNextSequenceRecv
since the invariance on ordered channels says "if packet sequence n times out, then a packet at sequence k > n cannot be received" as per ibc-go docs.UNORDERED
channels require a proof of non-existence via the packet receipt.This PR in it's final form will address the timeout issue as well as how packet sequences need to be handled on
ORDERED
channels but will be missing the logic for finishing the channel handshake process which is necessary for full interchain account support. Ideally we will be querying for recent txs and then looking forChannelOpenInit
in the events. If we noticed aChannelOpenInit
event then the relayer will attempt to finish the channel handshake.Right now we are waiting for two upstream changes which emit the version information in
ChannelOpenInit
. This is needed to parse the full channel information from the events.cosmos/ibc-go#1203
cosmos/ibc-go#1204
Closes #321