github NomicFoundation/hardhat hardhat@3.22.0
Hardhat v3.22.0

one hour ago

This release improves our experimental Amsterdam hardfork support, including adding EIP-8038: State-Access Gas Cost Update. Follow our Amsterdam guide to test your contracts against the updated gas costs.

Changes

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Added experimental EIP-8038 support to the Amsterdam hardfork: state-access operations are repriced.

  • #8832 4f6bcf5 - Thanks @popescuoctavian! Added the rollSlot(uint64) and getSlotNumber() cheatcodes, which set and read block.slotnum (EIP-7843) in Solidity tests without changing the block number or timestamp; both revert on EVM versions before Amsterdam.

  • #8832 4f6bcf5 - Thanks @popescuoctavian! Added the isIsolateMode() cheatcode, which returns whether the running Solidity test is run with isolate.

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Added the EIP-8037 gas dimensions to debug_traceTransaction and debug_traceCall from the Amsterdam hardfork: the default tracer's top-level frame and the callTracer's root call frame report executionGasUsed, stateGasUsed and gasRefund, and each structLogs entry reports stateGasReservoir, plus a signed stateGasCost on the steps that charge or refill state gas.

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Changed the experimental EIP-2780 support in the Amsterdam hardfork: contract-creation transactions no longer pay a value charge.

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Added the stateGasTracer to debug_traceTransaction and debug_traceCall, which reports a transaction's gas in both EIP-8037 dimensions on every hardfork, with zero state gas before Amsterdam.

  • #8800 4ae2908 Thanks @aelmanaa! - Running with the --coverage flag when no contracts are instrumented (i.e. --no-compile) now throws an error (#8796).

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Reduced the memory simulated networks use to record the call traces of executed transactions and calls.

  • #8832 4f6bcf5 - Thanks @popescuoctavian! Fixed block.slotnum returning 0 in forked Solidity tests instead of the forked block's slot number.

  • #8832 4f6bcf5 - Thanks @anaPerezGhiglia! Fixed missing EIP-8037 state gas for repeated contract deployments in Solidity tests on the Amsterdam hardfork.

  • #8832 4f6bcf5 - Thanks @popescuoctavian! Fixed Solidity tests switching to the default hardfork after vm.createSelectFork, vm.selectFork or vm.rollFork, instead of keeping the configured hardfork or inline evm_version.

  • #8787 4aa8b87 Thanks @Revinand! - Fixed --snapshot-check failing with HHE803 when .gas-snapshot has CRLF line endings, as in Windows checkouts.

  • #8812 c47ee42 Thanks @AliBaig-xD! - Fixed hardhat node --fork sending the configured forking httpHeaders to the URL passed on the command line.

  • #8712 81fc983 Thanks @schaable! - Fixed HHE905 errors on brief network failures by retrying the solc version list download.

  • #8824 197263c Thanks @aelmanaa! - Added a hidden includeTraces option to test solidity so plugins can collect call traces regardless of the verbosity (#8737).

  • #8832 4f6bcf5 Thanks @kanej! - Upgraded EDR to v0.25.1.


💡 The Nomic Foundation is hiring! Check our open positions.


Don't miss a new hardhat release

NewReleases is sending notifications on new releases.