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

sequencer, mempool: make mempool insertion errors distinct abci errors #1614

Closed
Lilyjjo opened this issue Oct 2, 2024 · 1 comment
Closed
Labels
mempool sequencer pertaining to the astria-sequencer crate

Comments

@Lilyjjo
Copy link
Contributor

Lilyjjo commented Oct 2, 2024

The mempool will reject transactions from the mempool when:

  • The nonce is too low (InsertionError::NonceTooLow)
  • There is already a transaction with that nonce for the account in the mempool (InsertionError::AlreadyPresent)
  • The parked account limit is hit (InsertionError::AccountSizeLimit)

We return these errors as AbciErrorCodes. Nonce too low has the code AbciErrorCode::INVALID_NONCE while the other two cases share TRANSACTION_INSERTION_FAILED. It might be nice to have distinct error codes for the other two cases as well.

┆Issue Number: ENG-900

@Lilyjjo Lilyjjo added sequencer pertaining to the astria-sequencer crate mempool labels Oct 2, 2024
@Lilyjjo
Copy link
Contributor Author

Lilyjjo commented Oct 31, 2024

Implemented in #1515

@Lilyjjo Lilyjjo closed this as completed Oct 31, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
mempool sequencer pertaining to the astria-sequencer crate
Projects
None yet
Development

No branches or pull requests

1 participant