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

feat: Archiver must handle L1 re-orgs gracefully. #8621

Open
Tracked by #7820
LHerskind opened this issue Sep 18, 2024 · 0 comments
Open
Tracked by #7820

feat: Archiver must handle L1 re-orgs gracefully. #8621

LHerskind opened this issue Sep 18, 2024 · 0 comments
Milestone

Comments

@LHerskind
Copy link
Contributor

LHerskind commented Sep 18, 2024

The current archiver lives in a fairy world where the base-layer never reorgs. By using only block numbers as its checkpoints it cannot tell if a re-org have happened and what do to about it. This can be an issue if for example blocks are pulled up till block 20, with no l2 blocks, it then re-orgs and there would have been a l2 block at block the "new" block 19. In this case, it would never find that block because it only starts looking at 20.

@github-project-automation github-project-automation bot moved this to Todo in A3 Sep 18, 2024
@LHerskind LHerskind added this to the Sequencer & Prover Testnet milestone Sep 24, 2024
LHerskind added a commit that referenced this issue Sep 26, 2024
Fixes #8620, by using the status function to figure out when a prune
have happened and unwind state. It do NOT tell the world state
synchronizer about the unwinding and that should be addressed as part of
#8665.

Adds tests to `e2e_synching` making sure that an archiver will correctly
catch the prune happening and delete the blocks and accompanying data.
Also adds e2e_synching to earthfile.

Removes the `proven_store` since we learn this from the status and it is
not more closely linked to the fetching of blocks.

Note that we are not handling L1 re-orgs specifically in here, but they
will for some cases be caught as well. But not all, so there is still
#8621 as well.

Fixes an issue where asking for block 0 would return block 1, as there
is no block 0. Explicitly return undefined if block 0 is requested now,
and gives an error if using `getBlocks` from a block that is before the
initial block.
Rumata888 pushed a commit that referenced this issue Sep 27, 2024
Fixes #8620, by using the status function to figure out when a prune
have happened and unwind state. It do NOT tell the world state
synchronizer about the unwinding and that should be addressed as part of
#8665.

Adds tests to `e2e_synching` making sure that an archiver will correctly
catch the prune happening and delete the blocks and accompanying data.
Also adds e2e_synching to earthfile.

Removes the `proven_store` since we learn this from the status and it is
not more closely linked to the fetching of blocks.

Note that we are not handling L1 re-orgs specifically in here, but they
will for some cases be caught as well. But not all, so there is still
#8621 as well.

Fixes an issue where asking for block 0 would return block 1, as there
is no block 0. Explicitly return undefined if block 0 is requested now,
and gives an error if using `getBlocks` from a block that is before the
initial block.
Rumata888 pushed a commit that referenced this issue Sep 27, 2024
Fixes #8620, by using the status function to figure out when a prune
have happened and unwind state. It do NOT tell the world state
synchronizer about the unwinding and that should be addressed as part of
#8665.

Adds tests to `e2e_synching` making sure that an archiver will correctly
catch the prune happening and delete the blocks and accompanying data.
Also adds e2e_synching to earthfile.

Removes the `proven_store` since we learn this from the status and it is
not more closely linked to the fetching of blocks.

Note that we are not handling L1 re-orgs specifically in here, but they
will for some cases be caught as well. But not all, so there is still
#8621 as well.

Fixes an issue where asking for block 0 would return block 1, as there
is no block 0. Explicitly return undefined if block 0 is requested now,
and gives an error if using `getBlocks` from a block that is before the
initial block.
Rumata888 pushed a commit that referenced this issue Sep 27, 2024
Fixes #8620, by using the status function to figure out when a prune
have happened and unwind state. It do NOT tell the world state
synchronizer about the unwinding and that should be addressed as part of
#8665.

Adds tests to `e2e_synching` making sure that an archiver will correctly
catch the prune happening and delete the blocks and accompanying data.
Also adds e2e_synching to earthfile.

Removes the `proven_store` since we learn this from the status and it is
not more closely linked to the fetching of blocks.

Note that we are not handling L1 re-orgs specifically in here, but they
will for some cases be caught as well. But not all, so there is still
#8621 as well.

Fixes an issue where asking for block 0 would return block 1, as there
is no block 0. Explicitly return undefined if block 0 is requested now,
and gives an error if using `getBlocks` from a block that is before the
initial block.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
Status: Todo
Development

No branches or pull requests

2 participants