From 3b5226a9900328be81bd9f6d30d60f5a0ea82587 Mon Sep 17 00:00:00 2001 From: ftheirs Date: Mon, 4 Nov 2024 16:45:43 -0300 Subject: [PATCH] local devnet: fix block 10 --- crates/bin/prove_block/src/lib.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/crates/bin/prove_block/src/lib.rs b/crates/bin/prove_block/src/lib.rs index f31354df..36fb9c3e 100644 --- a/crates/bin/prove_block/src/lib.rs +++ b/crates/bin/prove_block/src/lib.rs @@ -149,7 +149,7 @@ pub async fn prove_block( // This is a workaorund to catch the case where the block number is less than the buffer and still preserve the check // The OS will also handle the case where the block number is less than the buffer. let older_block_number = - if block_number <= STORED_BLOCK_HASH_BUFFER { 1 } else { block_number - STORED_BLOCK_HASH_BUFFER }; + if block_number <= STORED_BLOCK_HASH_BUFFER { 0 } else { block_number - STORED_BLOCK_HASH_BUFFER }; let older_block = match rpc_client.starknet_rpc().get_block_with_tx_hashes(BlockId::Number(older_block_number)).await? {