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

Handle two or more pre-confirmations at the same slot in the demo #107

Closed
thedevbirb opened this issue Jul 3, 2024 · 2 comments · Fixed by #110
Closed

Handle two or more pre-confirmations at the same slot in the demo #107

thedevbirb opened this issue Jul 3, 2024 · 2 comments · Fixed by #110
Labels
A: devnet Area: devnet T: bug Type: Bug
Milestone

Comments

@thedevbirb
Copy link
Contributor

There is an edge case in the frontend demo where sending two pre-confirmations rapidly in the same slot can cause the second one to fail with NonceTooLow error.
This is due to fact the nonce is obtained from the provider i.e. the execution state, which hasn't processed the pre-confirmed transaction yet, and as such the nonce of same transaction is the same of the first one.

In order to solve this, in the frontend we should increment the nonce of the account upon receiving the commitment from the sidecar

@thedevbirb thedevbirb added A: devnet Area: devnet T: bug Type: Bug labels Jul 3, 2024
@thedevbirb thedevbirb changed the title Handle pre-confirmation nonce increased in the demo Handle pre-confirmation nonce increase on same slot in the demo Jul 3, 2024
@thedevbirb thedevbirb changed the title Handle pre-confirmation nonce increase on same slot in the demo Handle two or more pre-confirmations at the same slot in the demo Jul 3, 2024
@mempirate
Copy link
Contributor

Maybe this can help: https://x.com/_jxom/status/1802851459072925900

@thedevbirb
Copy link
Contributor Author

On the sidecar there was an incorrect nonce inserted in the state diff, which has been fixed with the following commit: d074de9 (#62).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A: devnet Area: devnet T: bug Type: Bug
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants