Skip to content

Commit f46eb04

Browse files
authored
fix(env): fix next timestamp calculation (#130)
This is calculating a timestamp based on a block number, instead of a timestamp.
1 parent 13e6865 commit f46eb04

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/tasks/env.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -41,7 +41,7 @@ impl EnvTask {
4141
number: U256::from(previous.number + 1),
4242
beneficiary: self.config.builder_rewards_address,
4343
// NB: EXACTLY the same as the previous block
44-
timestamp: U256::from(previous.number + self.config.slot_calculator.slot_duration()),
44+
timestamp: U256::from(previous.timestamp + self.config.slot_calculator.slot_duration()),
4545
gas_limit: self.config.rollup_block_gas_limit,
4646
basefee: previous
4747
.next_block_base_fee(BaseFeeParams::ethereum())

0 commit comments

Comments
 (0)