From b15013155c4949f4445efa09feb0f98887e1b8d8 Mon Sep 17 00:00:00 2001 From: Ratan Kaliani Date: Tue, 10 Sep 2024 15:12:31 -0700 Subject: [PATCH] feat: cost estimator --- scripts/prove/bin/cost_estimator.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/scripts/prove/bin/cost_estimator.rs b/scripts/prove/bin/cost_estimator.rs index deb74709..07c31cd9 100644 --- a/scripts/prove/bin/cost_estimator.rs +++ b/scripts/prove/bin/cost_estimator.rs @@ -134,7 +134,8 @@ fn split_ranges(span_batch_ranges: Vec, l2_chain_id: u64) -> Vec while start < range.end { let end = min(start + batch_size, range.end); split_ranges.push(SpanBatchRange { start, end }); - start = end; + // The start of the next range should be the end of the current range + 1. + start = end + 1; } } else { split_ranges.push(range);