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

[block-producer]: improve InflightState error handling #537

Open
Mirko-von-Leipzig opened this issue Nov 1, 2024 · 0 comments
Open

[block-producer]: improve InflightState error handling #537

Mirko-von-Leipzig opened this issue Nov 1, 2024 · 0 comments

Comments

@Mirko-von-Leipzig
Copy link
Contributor

Follow-up task to #534.

InflightState and its submodule InflightAccountState currently panic instead of passing up errors. Both are also not as strict as they could be e.g. account state handles revert/commiting via an amount count instead of reverting/committing a given set of transaction IDs.

Effectively, account state should check that a given set of n transactions should

  • match the frontmost n transactions for commit, and
  • match the backmost n transactions for revert

Additionally, InflightState should not panic if the transaction delta is missing.

Effectively we should check that the transactions exist, and that they are being handled in the correct order.

Note that we probably want to consider transactions as unordered sets here, so that the bookkeeping at the mempool level can be relaxed. e.g. once transactions are rolled into batches, and batches into blocks, that we can erase the transaction ordering. At least within this component.

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

No branches or pull requests

1 participant