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

Host L1 txs: one-at-a-time to remove nonce risk #1839

Merged
merged 4 commits into from
Mar 19, 2024

Conversation

BedrockSquirrel
Copy link
Collaborator

Why this change is needed

Currently we try to optimistically manage L1 account nonce on the host. We only resync it to chain data on restart.

This has recently started to cause a conflict on ten-sepolia where rollup tx start failing continuously because the nonce is off.

Currently the only L1 transactions produced by the host are rollups and secret responses, there's no need to have multiple in flight simultaneously. Both the rollups and the secret exchange protocols can recover from delayed or dropped transactions.

What changes were made as part of this PR

Limit host to one L1 tx in flight at a time, blocking for the next one. This only adds contention at testnet network initializations really, when secret exchanges can be happening simultaneously as nodes start up.

The sim tests currently start the most nodes and we see a 10second increase in that test length with this change which seems reasonable for the simplification.

PR checks pre-merging

Please indicate below by ticking the checkbox that you have read and performed the required
PR checks

  • PR checks reviewed and performed

Copy link
Collaborator

@tudor-malene tudor-malene left a comment

Choose a reason for hiding this comment

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

lgtm

@BedrockSquirrel BedrockSquirrel merged commit 67b94d0 into main Mar 19, 2024
2 checks passed
@BedrockSquirrel BedrockSquirrel deleted the matt/l1-tx-nonce-conflicts branch March 19, 2024 13:13
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants