Skip to content
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

Antithesis: Skip checks if tx confirmation fails #3563

Merged
merged 22 commits into from
Nov 22, 2024

Conversation

StephenButtolph
Copy link
Contributor

@StephenButtolph StephenButtolph commented Nov 21, 2024

Why this should be merged

The Antithesis tests have been consistently failing because the workload incorrectly skips transaction confirmation.

Specifically:

  1. A transaction is issued to the network and marked as accepted on the API node.
  2. A node is killed by the antithesis framework.
  3. The transaction confirmation check is cancelled because the killed node is unresponsive
  4. We attempt to verify that the expected state transition happened even though the transaction may not have been accepted on all of the nodes yet.

Errors this PR should resolve:

  • failed to verify that X-chain UTXO was deleted
  • failed to verify that P-chain UTXO was deleted

How this works

If the transaction confirmation check is cancelled, we do not perform verification of the expected state transition.

How this was tested

Ran locally and didn't see any regressions.

Need to be documented in RELEASES.md?

No.

@StephenButtolph StephenButtolph added testing This primarily focuses on testing cleanup Code quality improvement labels Nov 21, 2024
@StephenButtolph StephenButtolph added this to the v1.11.14 milestone Nov 21, 2024
@StephenButtolph StephenButtolph self-assigned this Nov 21, 2024
@marun
Copy link
Contributor

marun commented Nov 21, 2024

Are you looking to see this merged before or after the zap PR?

marun and others added 15 commits November 21, 2024 20:24
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
Co-authored-by: Stephen Buttolph <[email protected]>
Signed-off-by: marun <[email protected]>
@StephenButtolph
Copy link
Contributor Author

I'm happy to rebase this on top of the zap PR

@StephenButtolph StephenButtolph changed the base branch from master to testing-switch-to-zap November 21, 2024 20:24
tests/antithesis/avalanchego/main.go Show resolved Hide resolved
Base automatically changed from testing-switch-to-zap to master November 21, 2024 22:39
)
return
}

w.verifyXChainTxConsumedUTXOs(ctx, operationTx)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

should this method be refactored to return an error? It seems to just log an error if one occurs during but then returns nothing.

I could create a follow up PR if so

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Because this function doesn't actually perform any modifications, it isn't required to propagate the error up... So that's why I didn't include that in this PR... But it certainly could.

@StephenButtolph StephenButtolph added this pull request to the merge queue Nov 22, 2024
Merged via the queue into master with commit 3fc0ba9 Nov 22, 2024
23 checks passed
@StephenButtolph StephenButtolph deleted the antithesis-skip-test-on-flaky-error branch November 22, 2024 18:52
@StephenButtolph StephenButtolph modified the milestones: v1.11.14, v1.12.0 Dec 9, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
cleanup Code quality improvement testing This primarily focuses on testing
Projects
Archived in project
Development

Successfully merging this pull request may close these issues.

3 participants