-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
fix: itest: fix eth deploy test flake #10829
Conversation
(validated by reducing the block times back to 100ms and ensuring that the test still passes) |
itests/eth_deploy_test.go
Outdated
@@ -93,6 +87,15 @@ func TestDeployment(t *testing.T) { | |||
pendingFilter, err := client.EthNewPendingTransactionFilter(ctx) | |||
require.NoError(t, err) | |||
|
|||
// Disconnect peers so we can send messages without propegating them. |
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 should work, but is it need easier to just pause and resume mining?
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 can do that?
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 can do that...
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.
Done.
This fixes the flakyness by: 1. Disconnecting the client from the miner before submitting the message. That way, we force it to get stuck in the message pool. 2. Removing the logic that asks lotus for the "latest" block. We have other tests that exercise "latest". fixes #10824
e4897e0
to
d7deb9a
Compare
Looks good to me! Is this error anything to be concerned about? https://app.circleci.com/pipelines/github/filecoin-project/lotus/28594/workflows/c7893a5e-2a10-4e48-a91a-afeb21fdaa23/jobs/962256?invite=true#step-104-510 |
Nope, that's intentional: lotus/itests/eth_deploy_test.go Lines 153 to 157 in e6c8072
(not sure why that's a part of the test, but it is) |
@@ -93,6 +88,11 @@ func TestDeployment(t *testing.T) { | |||
pendingFilter, err := client.EthNewPendingTransactionFilter(ctx) | |||
require.NoError(t, err) | |||
|
|||
// Pause so we can test that everything works while the message is in the message pool. | |||
for _, miner := range miners { |
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 just be the one miner because EnsembleMinimal
, but I'm good with this.
Related Issues
fixes #10824
Proposed Changes
This fixes the TestDeployment flakiness by: