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

fix(op): receipts import, fix chunked read of file with optional block data #10577

Merged
merged 2 commits into from
Aug 28, 2024

Conversation

emhane
Copy link
Member

@emhane emhane commented Aug 27, 2024

Ref #10580

Receipts are exported by geth and erigon as lists of lists, where each list maps to a block number. If there are no receipts for some block, that is encoded as an empty list. Read of big receipt file in chunks, cannot assume an empty block at start of chunk is genesis block.

  • Computes first block number of ReceiptFileClient w.r.t. previous chunk

@emhane emhane added A-downloaders Related to headers/bodies downloaders A-op-reth Related to Optimism and op-reth labels Aug 27, 2024
@emhane emhane marked this pull request as draft August 27, 2024 20:17
@emhane emhane marked this pull request as ready for review August 27, 2024 21:54
Copy link
Collaborator

@mattsse mattsse left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nice catch

@emhane emhane added this pull request to the merge queue Aug 28, 2024
Merged via the queue into main with commit 0b6480c Aug 28, 2024
34 checks passed
@emhane emhane deleted the emhane/fix-import-receipts branch August 28, 2024 08:16
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
A-downloaders Related to headers/bodies downloaders A-op-reth Related to Optimism and op-reth
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants