From 6a82fce7c285b3d9d306be9708a29570f8b2f75f Mon Sep 17 00:00:00 2001 From: David Nevado Date: Wed, 21 Jun 2023 00:20:14 +0200 Subject: [PATCH] Fix max_exp_steps param --- bus-mapping/src/circuit_input_builder.rs | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/bus-mapping/src/circuit_input_builder.rs b/bus-mapping/src/circuit_input_builder.rs index b2b5c20560..5d3c1b582f 100644 --- a/bus-mapping/src/circuit_input_builder.rs +++ b/bus-mapping/src/circuit_input_builder.rs @@ -346,7 +346,11 @@ impl CircuitInputBuilder { .transactions .iter() .fold(0, |acc, tx| acc + tx.input.len()); - let max_exp_steps = self.block.exp_events.len(); + let max_exp_steps = self + .block + .exp_events + .iter() + .fold(0usize, |acc, e| acc + e.steps.len()); // The `+ 2` is used to take into account the two extra empty copy rows needed // to satisfy the query at `Rotation(2)` performed inside of the // `rows[2].value == rows[0].value * r + rows[1].value` requirement in the RLC