From c17798c4faa0620f0d18d1bab019152a47ac5103 Mon Sep 17 00:00:00 2001 From: juztamau5 Date: Sat, 11 Feb 2023 17:23:46 -0800 Subject: [PATCH] Allow large contracts on local networks Fixes error: Error: Transaction reverted: trying to deploy a contract whose code is too large --- onchain/rollups/hardhat.config.ts | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/onchain/rollups/hardhat.config.ts b/onchain/rollups/hardhat.config.ts index 1828ac8e..2d2a680c 100644 --- a/onchain/rollups/hardhat.config.ts +++ b/onchain/rollups/hardhat.config.ts @@ -47,10 +47,14 @@ const infuraNetwork = ( const config: HardhatUserConfig = { networks: { - hardhat: mnemonic ? { accounts: { mnemonic } } : {}, + hardhat: { + accounts: mnemonic ? { mnemonic } : undefined, + allowUnlimitedContractSize: true, + }, localhost: { url: "http://localhost:8545", accounts: mnemonic ? { mnemonic } : undefined, + allowUnlimitedContractSize: true, }, mainnet: infuraNetwork("mainnet", 1, 6283185), goerli: infuraNetwork("goerli", 5, 6283185),