Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
45 commits
Select commit Hold shift + click to select a range
a04f6b7
test: move calldata to files
greged93 Mar 21, 2025
4c328cc
feat: batch header decoding
greged93 Mar 21, 2025
53af94f
feat: improve codec interface
greged93 Mar 21, 2025
c17d65e
chore: manifests fixes
greged93 Mar 21, 2025
a2929e0
feat: revert some codec changes
greged93 Mar 24, 2025
05cc350
feat: wip derivation pipeline
greged93 Mar 24, 2025
54a557c
feat: batch header v7
greged93 Mar 24, 2025
a5e31c9
feat: add batch abstraction
greged93 Mar 24, 2025
57c0992
feat: basic derivation pipeline
greged93 Mar 24, 2025
2edae45
feat: implement batch data hash
greged93 Mar 24, 2025
113f18e
feat: move PayloadData
greged93 Mar 25, 2025
9186662
feat: improve batch data hash computation
greged93 Mar 25, 2025
42bbace
test: derivation
greged93 Mar 25, 2025
50962ca
chore: cleaning
greged93 Mar 25, 2025
2aa6b85
fix: lints
greged93 Mar 25, 2025
32e56fc
fix: lints
greged93 Mar 25, 2025
2f56e24
fix: skip wasm for derivation pipeline
greged93 Mar 25, 2025
fb85ecf
fix: data hash computation for batch
greged93 Mar 26, 2025
6341957
Merge branch 'main' into feat/derivation-pipeline
greged93 Mar 26, 2025
23be55b
fix: lint
greged93 Mar 26, 2025
df9d787
fix: lint
greged93 Mar 26, 2025
4bba46d
fix: lints
greged93 Mar 26, 2025
485f66c
fix: answer comments
greged93 Apr 1, 2025
b1b223e
fix: lints
greged93 Apr 1, 2025
1cf831a
feat: wip
greged93 Mar 25, 2025
f1de162
feat: changes to the data model
greged93 Mar 26, 2025
86f3880
fix: codec issue
greged93 Mar 26, 2025
a8f18d9
feat: modify derivation pipeline to fetch blob
greged93 Mar 26, 2025
d5c7313
test: move test data to file
greged93 Mar 26, 2025
3a6da41
fix: lints
greged93 Mar 26, 2025
eeb7a63
fix: answer comments
greged93 Apr 1, 2025
52f35cf
test: fix migration
greged93 Apr 1, 2025
0e5fa79
Merge branch 'main' into feat/integrate-batch-changes
greged93 Apr 2, 2025
72831db
fix: comments
greged93 Apr 2, 2025
82cbcac
feat: providers crate
greged93 Mar 26, 2025
27c0c59
feat: l1 providers crate
greged93 Mar 26, 2025
e5be688
feat: l1 provider implementation
greged93 Mar 27, 2025
b4188fa
feat: l1 message provider
greged93 Mar 27, 2025
59c1603
feat: pipeline modifications
greged93 Mar 27, 2025
58c1e8e
fix: avoid iterating the cache
greged93 Mar 27, 2025
b47d913
chore: simplify derivation pipeline interface
greged93 Apr 1, 2025
1ceab4f
fix: lints
greged93 Apr 1, 2025
1fe124e
fix: rebasing
greged93 Apr 1, 2025
aca4f24
fix: answer comments
greged93 Apr 2, 2025
aa37234
Merge branch 'main' into feat/providers
greged93 Apr 3, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/lint.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -128,11 +128,11 @@ jobs:
- type: wasm
target: wasm32-unknown-unknown
exclude: |
scroll-engine,scroll-wire,rollup-node,scroll-network,rollup-node-manager,rollup-node-watcher,scroll-db,scroll-migration,rollup-node-indexer,scroll-derivation-pipeline
scroll-engine,scroll-wire,rollup-node,scroll-network,rollup-node-manager,rollup-node-watcher,scroll-db,scroll-migration,rollup-node-indexer,scroll-derivation-pipeline,rollup-node-providers
- type: riscv
target: riscv32imac-unknown-none-elf
exclude: |
scroll-engine,scroll-wire,rollup-node,scroll-network,rollup-node-manager,rollup-node-watcher,scroll-db,scroll-migration,rollup-node-indexer,scroll-codec,scroll-derivation-pipeline
scroll-engine,scroll-wire,rollup-node,scroll-network,rollup-node-manager,rollup-node-watcher,scroll-db,scroll-migration,rollup-node-indexer,scroll-codec,scroll-derivation-pipeline,rollup-node-providers
steps:
- uses: actions/checkout@v4
- uses: rui314/setup-mold@v1
Expand Down
87 changes: 87 additions & 0 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,7 @@ members = [
"crates/node",
"crates/network",
"crates/primitives",
"crates/providers",
"crates/scroll-wire",
"crates/watcher",
]
Expand Down Expand Up @@ -152,6 +153,7 @@ reth-scroll-primitives = { git = "https://github.com/scroll-tech/reth.git", defa
rollup-node-indexer = { path = "crates/indexer" }
rollup-node-manager = { path = "crates/node" }
rollup-node-primitives = { path = "crates/primitives" }
rollup-node-providers = { path = "crates/providers" }
rollup-node-watcher = { path = "crates/watcher" }
scroll-codec = { path = "crates/codec" }
scroll-db = { path = "crates/database/db" }
Expand Down
5 changes: 5 additions & 0 deletions crates/database/db/src/models/batch_commit.rs
Original file line number Diff line number Diff line change
Expand Up @@ -11,6 +11,7 @@ pub struct Model {
index: i64,
hash: Vec<u8>,
block_number: i64,
block_timestamp: i64,
calldata: Vec<u8>,
blob_hash: Option<Vec<u8>>,
finalized_block_number: Option<i64>,
Expand All @@ -33,6 +34,9 @@ impl From<BatchCommitData> for ActiveModel {
block_number: ActiveValue::Set(
batch_commit.block_number.try_into().expect("block number should fit in i64"),
),
block_timestamp: ActiveValue::Set(
batch_commit.block_timestamp.try_into().expect("block timestamp should fit in i64"),
),
calldata: ActiveValue::Set(batch_commit.calldata.0.to_vec()),
blob_hash: ActiveValue::Set(batch_commit.blob_versioned_hash.map(|b| b.to_vec())),
finalized_block_number: ActiveValue::Unchanged(None),
Expand All @@ -46,6 +50,7 @@ impl From<Model> for BatchCommitData {
hash: value.hash.as_slice().try_into().expect("data persisted in database is valid"),
index: value.index as u64,
block_number: value.block_number as u64,
block_timestamp: value.block_timestamp as u64,
calldata: Arc::new(value.calldata.into()),
blob_versioned_hash: value
.blob_hash
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,7 @@ impl MigrationTrait for Migration {
.col(pk_auto(BatchCommit::Index))
.col(binary_len(BatchCommit::Hash, HASH_LENGTH))
.col(big_unsigned(BatchCommit::BlockNumber))
.col(big_unsigned(BatchCommit::BlockTimestamp))
.col(binary(BatchCommit::Calldata))
.col(binary_len_null(BatchCommit::BlobHash, HASH_LENGTH))
.col(boolean_null(BatchCommit::FinalizedBlockNumber))
Expand All @@ -36,6 +37,7 @@ enum BatchCommit {
Index,
Hash,
BlockNumber,
BlockTimestamp,
Calldata,
BlobHash,
FinalizedBlockNumber,
Expand Down
3 changes: 3 additions & 0 deletions crates/derivation-pipeline/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,14 +22,17 @@ scroll-alloy-rpc-types-engine.workspace = true

# rollup node
rollup-node-primitives.workspace = true
rollup-node-providers.workspace = true
scroll-codec.workspace = true

# misc
thiserror.workspace = true

[dev-dependencies]
async-trait.workspace = true
eyre.workspace = true
scroll-codec = { workspace = true, features = ["test-utils"] }
tokio = { workspace = true, features = ["macros"] }

[features]
default = ["std"]
Expand Down
7 changes: 7 additions & 0 deletions crates/derivation-pipeline/src/error.rs
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
use rollup_node_providers::L1ProviderError;
use scroll_codec::CodecError;

/// An error occurred during the derivation process.
Expand All @@ -9,4 +10,10 @@ pub enum DerivationPipelineError {
/// Missing L1 messages cursor.
#[error("missing l1 message queue cursor")]
MissingL1MessageQueueCursor,
/// Missing L1 message.
#[error("missing l1 message")]
MissingL1Message,
/// An error at the L1 provider.
#[error(transparent)]
L1Provider(#[from] L1ProviderError),
}
Loading
Loading