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

EVM construct block #2272

Merged
merged 24 commits into from
Aug 4, 2023
Merged

EVM construct block #2272

merged 24 commits into from
Aug 4, 2023

Conversation

sieniven
Copy link
Contributor

@sieniven sieniven commented Aug 2, 2023

Summary

  • Pipeline to validate and execute transactions and update the new state into the block in finalize_block is shifted out into construct_block.
  • Once the construction is done in a particular txqueue, the queue now holds the newly minted block in the queue.
  • finalize_block will be called to commit the state and connect the block into storage. The old pipeline runs finalize_block twice (in ConnectBlock and subsequently in ConnectTip). This prevents redoing and running the block creation again.

Bug fixes

  • Fix txqueue clear and drain_all methods bug to clear account nonce index.

Housekeeping

  • Tidy up and add in description for evm tx validation pipeline.

Implications

  • Storage

    • Database reindex required
    • Database reindex optional
    • Database reindex not required
    • None
  • Consensus

    • Network upgrade required
    • Includes backward compatible changes
    • Includes consensus workarounds
    • Includes consensus refactors
    • None

lib/ain-evm/src/evm.rs Outdated Show resolved Hide resolved
Jouzo
Jouzo previously approved these changes Aug 2, 2023
Jouzo
Jouzo previously approved these changes Aug 3, 2023
lib/ain-evm/src/txqueue.rs Outdated Show resolved Hide resolved
@sieniven sieniven requested a review from Jouzo August 3, 2023 08:00
Jouzo
Jouzo previously approved these changes Aug 3, 2023
@sieniven sieniven requested a review from Jouzo August 4, 2023 10:44
Jouzo
Jouzo previously approved these changes Aug 4, 2023
@prasannavl prasannavl merged commit ed30200 into master Aug 4, 2023
@prasannavl prasannavl deleted the evm/create-block branch August 4, 2023 14:56
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.

3 participants