go-ethereum/core/rawdb
Jonas Theis 40ebbd6491
feat(L1 follower): adjust to recent CodecV7 and contract changes (#1120)
* port changes from #1013

* port changes from #1068

* go.mod tidy

* fix compile error

* fix goimports

* fix log

* address review comments

* upgrade golang.org/x/net to 0.23.0

* port changes from #1018

* fix tests and linter errors

* address review comments

* refactor rollup sync service / verifier to use CalldataBlobSource to retrieve data from L1

* add configuration and initialize blob clients

* fix unit tests

* remove unused code

* address review comments

* address more review comments

* implement first version of new da-codec and to handle multiple batches submitted in one transaction

* add CommitBatchDAV7 and handle multiple commit events submitted in a single transactions

* fix bug due to previous batch being empty when processing the first batch within a set of batches

* Allow using MPT

* update to latest da-codec

* add field to CommittedBatchMeta to store LastL1MessageQueueHash for CodecV7 batches

* adjust rollup verifier to support CodecV7 batches

* address review comments

* fix issues after merge

* go mod tidy

* fix unit tests

* update da-codec

* add test TestValidateBatchCodecV7

* go mod tidy

* do not log error on shutdown

* add sanity check for version to deserialization of committedBatchMetaV7

* port changes from #1073

* chore: auto version bump [bot]

* address review comments

* add more logs

* disable ENRUpdater if DA sync mode is enabled

* exit pipeline if context is cancelled

* correctly handle override by setting the head of the chain to the parent's height so that created blocks will always become part of canonical chain

* fix error with genesis event being nil

* chore: auto version bump [bot]

* chore: auto version bump [bot]

* adjust to renaming in CodecV7

* implement carrying forward of L1 MessageQueue index

* fix issue after upgrading from old storage to new format where batchIndex was 0 and all batches would be skipped

* add new RevertBatch event

* add commitBatches to be able to read calldata of CodecV7/EuclidV2 committed batches

* implement finding of L1 message queue height for initial batch in recovery mode

* add sanity checks for computed batches from events and batch hashes given via calldata from commit transaction

* update ScrollChain ABI

* chore: auto version bump [bot]

* remove initial batch form DAQueue

* go mod tidy

* fix underflow bug when l1DeploymentBlock==0

* fix bug with wrong parentBatchHash of first batch of batches submitted in a single tx

* update to latest da-codec

* address review comments

* address review comments

* fix bug when l1MessageV2StartIndex==0 serialized to [] (empty slice) which would always be decoded to non-existing instead of 0

* chore: auto version bump [bot]

* cache go dependencies in Dockerfile.mockccc

* chore: auto version bump [bot]

* add INFO log when reverting rollup events in L1 follower mode

* change LastProcessedMessageQueueIndex of finalize event to  totalL1MessagesPoppedOverall

* cleanup

* chore: auto version bump [bot]

---------

Co-authored-by: Ömer Faruk Irmak <omerfirmak@gmail.com>
Co-authored-by: Thegaram <Thegaram@users.noreply.github.com>
Co-authored-by: jonastheis <jonastheis@users.noreply.github.com>
2025-03-03 13:14:32 +01:00
..
testdata core/rawdb: avoid unnecessary receipt processing for log filtering (#23147) 2021-09-28 12:54:49 +02:00
accessors_chain.go feat: add EIP-7702 (#1112) 2025-02-25 14:56:51 +01:00
accessors_chain_test.go feat: add EIP-7702 (#1112) 2025-02-25 14:56:51 +01:00
accessors_da_syncer.go feat(L1 follower): adjust to recent CodecV7 and contract changes (#1120) 2025-03-03 13:14:32 +01:00
accessors_indexes.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
accessors_indexes_test.go Add goimports lint (#54) 2022-03-24 16:53:59 +08:00
accessors_l1_message.go feat(L1 follower): adjust to recent CodecV7 and contract changes (#1120) 2025-03-03 13:14:32 +01:00
accessors_l1_message_test.go feat(MessageQueueV2): add reading of MessageQueueV2 and transition logic from V1 to V2 for EuclidV2 (#1108) 2025-02-14 12:57:07 +01:00
accessors_metadata.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
accessors_rollup_event.go feat(L1 follower): adjust to recent CodecV7 and contract changes (#1120) 2025-03-03 13:14:32 +01:00
accessors_rollup_event_test.go feat(L1 follower): adjust to recent CodecV7 and contract changes (#1120) 2025-03-03 13:14:32 +01:00
accessors_row_consumption.go feat: implement and integrate counter-based CCC (#982) 2024-09-04 13:33:51 +03:00
accessors_row_consumption_test.go feat(rollup): add circuits capacity checker (#321) 2023-08-01 13:52:31 +08:00
accessors_skipped_txs.go feat(tx-pool): fast reject known skipped txs (#1004) 2024-08-26 22:48:44 +08:00
accessors_skipped_txs_test.go feat(api/rawdb): allow storing traces for skipped txs (#500) 2023-09-05 11:03:15 +08:00
accessors_snapshot.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
accessors_state.go feat: Add support for L1 MPT (#1104) 2025-02-05 14:57:40 +01:00
chain_iterator.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
chain_iterator_test.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
database.go fix: use non-overlapping DB prefix for L1 messages (#532) 2023-10-04 19:28:26 +02:00
database_test.go eth/protocols/snap: generate storage trie from full dirty snap data (#22668) 2021-04-27 17:19:59 +03:00
freezer.go style: revert some formatting (#294) 2023-04-20 17:49:35 +08:00
freezer_batch.go Add goimports lint (#54) 2022-03-24 16:53:59 +08:00
freezer_table.go Add goimports lint (#54) 2022-03-24 16:53:59 +08:00
freezer_table_test.go Add goimports lint (#54) 2022-03-24 16:53:59 +08:00
freezer_test.go Add goimports lint (#54) 2022-03-24 16:53:59 +08:00
schema.go feat(MessageQueueV2): add reading of MessageQueueV2 and transition logic from V1 to V2 for EuclidV2 (#1108) 2025-02-14 12:57:07 +01:00
table.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00
table_test.go Update mod file and all imports to use scroll-tech URL (#15) 2021-12-24 10:59:22 +01:00