Skip to content

Commit

Permalink
chore: change meaning of l1 one gas price constant (#598)
Browse files Browse the repository at this point in the history
  • Loading branch information
elfedy authored Oct 1, 2024
1 parent 46d9f92 commit cc27c50
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions crates/zksync/core/src/vm/inspect.rs
Original file line number Diff line number Diff line change
Expand Up @@ -53,8 +53,8 @@ use foundry_evm_abi::{
patch_hh_console_selector, Console, HardhatConsole, HARDHAT_CONSOLE_ADDRESS,
};

/// Maximum gas price allowed for L1.
const MAX_L1_GAS_PRICE: u64 = 1000;
/// Minimum gas price allowed for L1.
const MIN_L1_GAS_PRICE: u64 = 1000;

/// Represents the result of execution a [`L2Tx`] on EraVM
#[derive(Debug)]
Expand Down Expand Up @@ -416,7 +416,7 @@ fn inspect_inner<S: ReadStorage>(
ccx: &mut CheatcodeTracerContext,
call_ctx: CallContext,
) -> InnerZkVmResult {
let l1_gas_price = call_ctx.block_basefee.to::<u64>().max(MAX_L1_GAS_PRICE);
let l1_gas_price = call_ctx.block_basefee.to::<u64>().max(MIN_L1_GAS_PRICE);
let fair_l2_gas_price = call_ctx.block_basefee.saturating_to::<u64>();
let batch_env = create_l1_batch_env(storage.clone(), l1_gas_price, fair_l2_gas_price);

Expand Down

0 comments on commit cc27c50

Please sign in to comment.