-
Notifications
You must be signed in to change notification settings - Fork 648
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
feat: adding hermes to e2e tests. #3408
feat: adding hermes to e2e tests. #3408
Conversation
@@ -50,7 +50,7 @@ on: | |||
relayer-type: | |||
description: "The type of relayer to use" | |||
required: false | |||
default: "rly" | |||
default: "hermes" |
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.
Temporarily, for checking test results
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.
will we be reverting this before merging?
type: string | ||
relayer-tag: | ||
description: "The tag to use for the relayer" | ||
required: false | ||
default: "" # the tests themselves will choose a sensible default when unset. | ||
default: "1.4.0" # the tests themselves will choose a sensible default when unset. |
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, temporarily.
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.
also reverting this
810d6f4
to
f44dd9a
Compare
Pending upstream merge of the changes in |
2831435
to
3fb3004
Compare
ab3f9b5
to
77bc38d
Compare
So, the biggest changes here are basically the need to add the following after the hermes relayer starts:
it appears as if some time is always required before hermes is able to see that packets have been relayed after starting, one explanation for this is possibly that its startup time is slower than that for rly. I think it shouldn't be too hard to add the previous snippet in |
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.
LGTM! Happy to approve, just curious if we can figure out a way to reduce diffs and hopefully decrease the time spent debugging missing wait commands?
cosmosRelayerUser = "100:1000" // docker run -it --rm --entrypoint echo ghcr.io/cosmos/relayer "$(id -u):$(id -g)" | ||
hermesRelayerRepository = "ghcr.io/informalsystems/hermes" | ||
hermesRelayerUser = "1000:1000" | ||
rlyRelayerRepository = "damiannolan/rly" //"ghcr.io/cosmos/relayer" |
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 this be changed back?
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.
nope, these are used when creating the relayer in newHermesRelayer
:
Line 61 in 77bc38d
customImageOption := relayer.CustomDockerImage(hermesRelayerRepository, tag, hermesRelayerUser) |
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.
sorry I mean't the damiannolan/rly
string?
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.
ah, right, that's pending on cosmos/relayer#1102
hermesRelayerRepository = "ghcr.io/informalsystems/hermes" | ||
hermesRelayerUser = "1000:1000" | ||
rlyRelayerRepository = "damiannolan/rly" //"ghcr.io/cosmos/relayer" | ||
rlyRelayerUser = "100:1000" // docker run -it --rm --entrypoint echo ghcr.io/cosmos/relayer "$(id -u):$(id -g)" |
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 there's a public function for this now, but can't remember
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.
Here we are
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.
looked into this. Using a custom image (like we currently do) doesn't use the defaults. Can't use the defaults for rly
since we're based on Damian's forked image, can't use the default for hermes since interchaintest
hasn't updated their registry url (still points to docker rather than ghcr
+ is on version 1.2.0). I'll probably open a PR for the second case on interchaintest and we can drop both consts for hermes.
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.
cool, once we switch off damian's image (probably after v7.1 release) then we can move to the defaults. Is there an issue to track this work? If not, maybe we can open an issue
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.
If not, maybe we can open an issue
yup! done with #3615
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.
re: hermes image/tag updates done strangelove-ventures/interchaintest#571
33f17ed
to
77bc38d
Compare
e34b306
to
7931429
Compare
7931429
to
777fced
Compare
Hey guys, just want to remind you all that Hermes v1.5 is out. It might be worth updating to the latest version of Hermes in your tests 🙂 |
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.
Thank you @DimitrisJim!! 🎉
thanks for the heads up @seanchen1991 I'll bump it now since we hardcode it atm in our tests until we can update to the latest interchaintest version (which should also be bumped!) |
23bd0e7
to
590046d
Compare
590046d
to
07b76fb
Compare
Think this should be gtg (will rollback temporary changes to workflow files when necessary). Waiting for ten blocks does suffice for hermes in this case. Re: bumping to I think its fine if we punt this to a later point. Hopefully, we'll be able to sync up with latest |
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.
LGTM!
If we have all tests passing with hermes (or at least all the ones we know should be passing)
I would be happy to merge this once we revert to the go relayer as default and then we can discuss what we want to do re hermes/rly for our PRs/compatibility testing etc in a future discussion1
thanks for all the work on this!
The LOC does not reflect the effort you put in to get this all working 🥇
@@ -128,7 +128,7 @@ func (s *E2ETestSuite) SetupChainsRelayerAndChannel(ctx context.Context, channel | |||
} | |||
}) | |||
// wait for relayer to start. | |||
time.Sleep(time.Second * 10) | |||
s.Require().NoError(test.WaitForBlocks(ctx, 10, chainA, chainB), "failed to wait for blocks") |
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.
this is what we will be able to remove in the future right?
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.
Considering this was in place with rly
(only in sleep form) maybe we'll always need to give relayers some time to get up and running. Ideally, we should be able to drop this to 5 blocks (bumped it to 10 for hermes since 5 resulted in old familiar errors indicating that it needed more time).
@@ -50,7 +50,7 @@ on: | |||
relayer-type: | |||
description: "The type of relayer to use" | |||
required: false | |||
default: "rly" | |||
default: "hermes" |
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.
will we be reverting this before merging?
type: string | ||
relayer-tag: | ||
description: "The tag to use for the relayer" | ||
required: false | ||
default: "" # the tests themselves will choose a sensible default when unset. | ||
default: "1.4.0" # the tests themselves will choose a sensible default when unset. |
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.
also reverting this
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.
Latest changes ACK
If we have all tests passing with hermes (or at least all the ones we know should be passing)
I would be happy to merge this once we revert to the go relayer as default and then we can discuss what we want to do re hermes/rly for our PRs/compatibility testing etc in a future discussion1
thanks for all the work on this!
The LOC does not reflect the effort you put in to get this all working 🥇
Description
closes: #3315
Commit Message / Changelog Entry
feat: integrating hermes in our e2e tests
see the guidelines for commit messages. (view raw markdown for examples)
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.
docs/
) or specification (x/<module>/spec/
).godoc
comments.Files changed
in the Github PR explorer.Codecov Report
in the comment section below once CI passes.