Skip to content

Commit e906ab3

Browse files
committed
test(example-event-handlers): pin in-container hardfork to cancun
The hardhat node in examples/ethereum-basic-event-handlers/hardhat runs with `"hardhat": "^2.22.1"` and no lockfile, so each CI run picks the latest matching release (currently 2.28.6). Hardhat 2.26+ defaults to the Prague hardfork, which enforces EIP-7825's per- transaction gas cap of 2^24 (16,777,216). The test contract deploy needs ~30M gas and gets rejected with `ProviderError: Transaction gas limit is 30000000 and exceeds transaction gas cap of 16777216`. Pinning the in-container network's hardfork to `cancun` restores pre-EIP-7825 behavior without locking the hardhat version.
1 parent 221ca99 commit e906ab3

1 file changed

Lines changed: 7 additions & 0 deletions

File tree

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,10 @@
11
module.exports = {
22
solidity: '0.8.9',
3+
networks: {
4+
hardhat: {
5+
// Pin to Cancun: Prague (default in hardhat >=2.26) enforces EIP-7825's
6+
// per-transaction gas cap of 2^24, which rejects the test deployments.
7+
hardfork: 'cancun',
8+
},
9+
},
310
};

0 commit comments

Comments
 (0)