Skip to content

Commit

Permalink
Merge pull request #1236 from lambdaclass/optional-commit_data_generator
Browse files Browse the repository at this point in the history
fix(Validium): Make `l1_batch_commit_data_generator_mode` a non-mandatory attribute
  • Loading branch information
ilitteri committed Feb 28, 2024
2 parents 6310305 + 7692025 commit c6e3fe8
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 1 deletion.
2 changes: 1 addition & 1 deletion core/lib/config/src/configs/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ pub struct StateKeeperConfig {

/// Number of keys that is processed by enum_index migration in State Keeper each L1 batch.
pub enum_index_migration_chunk_size: Option<usize>,

#[serde(default)]
pub l1_batch_commit_data_generator_mode: L1BatchCommitDataGeneratorMode,
}

Expand Down
8 changes: 8 additions & 0 deletions core/lib/env_config/src/chain.rs
Original file line number Diff line number Diff line change
Expand Up @@ -207,4 +207,12 @@ mod tests {
let actual = CircuitBreakerConfig::from_env().unwrap();
assert_eq!(actual, expected_circuit_breaker_config());
}

#[test]
fn default_state_keeper_mode() {
assert_eq!(
StateKeeperConfig::default().l1_batch_commit_data_generator_mode,
L1BatchCommitDataGeneratorMode::Rollup
);
}
}

0 comments on commit c6e3fe8

Please sign in to comment.