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.
Closes: #XXX
Context
The Problem
With ibc-go v7, the keeper function SendTx was deprecated in favor of the msg_server function...
Whereas the timestamp in the keeper function was an absolute timestamp (i.e. the timeout in unix nano), the timestamp that should be passed into
NewMsgSendTx
is a relative timestamp (i.e. the offset in nano seconds between the current time and the timeout timestamp).As the code lives on main, the absolute timestamp is being passed into
NewMsgSendTx
, which is causing the end timestamp to be essentially doubled:# Ex: Current Time: 1000 Desired Timeout: 1010 NewMsgSendTx(1010) → Returns absolute timestamp of 2010
The Solution
There are two solutions here:
Considering option (1) would involve a big refactor, I think it makes sense to move forward with option (2) in the short term.
Brief Changelog