NethermindEth / juno

Starknet client implementation.

Home Page:https://juno.nethermind.io

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Pending Block and State can become out of sync

IronGauntlets opened this issue · comments

Pending Block and State are written to the DB this means that any subsequent runs of Juno when pending-poll is disabled would have access to the old Pending Block and State which is no longer relevant.

There are 2 solutions:

  • Stop persisting the pending block and state across multiple runs of Juno and only manage it in memory. This may require a migration to remove the old pending block.
  • Check if the pending block is outdated and return ErrBlockNotFound.

This should be done along with #1787