diff --git a/crates/sequencing/papyrus_consensus_orchestrator/src/sequencer_consensus_context.rs b/crates/sequencing/papyrus_consensus_orchestrator/src/sequencer_consensus_context.rs index 8d5b05b7dbf..9707c427df2 100644 --- a/crates/sequencing/papyrus_consensus_orchestrator/src/sequencer_consensus_context.rs +++ b/crates/sequencing/papyrus_consensus_orchestrator/src/sequencer_consensus_context.rs @@ -146,6 +146,7 @@ impl ConsensusContext for SequencerConsensusContext { block_timestamp: BlockTimestamp( now.timestamp().try_into().expect("Failed to convert timestamp"), ), + use_kzg_da: true, ..Default::default() }, }; @@ -213,6 +214,7 @@ impl ConsensusContext for SequencerConsensusContext { block_timestamp: BlockTimestamp( now.timestamp().try_into().expect("Failed to convert timestamp"), ), + use_kzg_da: true, ..Default::default() }, }; diff --git a/crates/starknet_api/src/block.rs b/crates/starknet_api/src/block.rs index 74f72a462d9..8852e706c60 100644 --- a/crates/starknet_api/src/block.rs +++ b/crates/starknet_api/src/block.rs @@ -486,7 +486,7 @@ impl GasPrices { )] pub struct BlockTimestamp(pub u64); -#[derive(Clone, Debug, Deserialize, Default, Serialize)] +#[derive(Clone, Debug, Deserialize, Serialize)] pub struct BlockInfo { pub block_number: BlockNumber, pub block_timestamp: BlockTimestamp, @@ -497,6 +497,18 @@ pub struct BlockInfo { pub use_kzg_da: bool, } +impl Default for BlockInfo { + fn default() -> Self { + Self { + block_number: BlockNumber::default(), + block_timestamp: BlockTimestamp::default(), + sequencer_address: ContractAddress::default(), + gas_prices: GasPrices::default(), + use_kzg_da: true, + } + } +} + /// The signature of a [Block](`crate::block::Block`), signed by the sequencer. The signed message /// is defined as poseidon_hash(block_hash, state_diff_commitment). #[derive(