From b0a2e67cc11b5f8573f386e199964161a60b8229 Mon Sep 17 00:00:00 2001 From: Garvit Khatri Date: Sun, 8 Dec 2024 23:23:00 +0000 Subject: [PATCH 1/2] Deploy estimations by default always --- src/cli/config/options.ts | 2 +- src/cli/deploySimulationsContract.ts | 10 ++++++++++ 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/src/cli/config/options.ts b/src/cli/config/options.ts index 6e1e5e86..6c3079f4 100644 --- a/src/cli/config/options.ts +++ b/src/cli/config/options.ts @@ -469,7 +469,7 @@ export const debugOptions: CliCommandOptions = { "Should the bundler deploy the simulations contract on startup", type: "boolean", require: true, - default: false + default: true }, tenderly: { description: "RPC url follows the tenderly format", diff --git a/src/cli/deploySimulationsContract.ts b/src/cli/deploySimulationsContract.ts index da950b4f..9b9be004 100644 --- a/src/cli/deploySimulationsContract.ts +++ b/src/cli/deploySimulationsContract.ts @@ -24,6 +24,16 @@ export const deploySimulationsContract = async ({ ) } + if (args.entrypointSimulationContract) { + const simulations = args.entrypointSimulationContract + const simulationsCode = await publicClient.getCode({ + address: simulations + }) + if (simulationsCode !== undefined && simulationsCode !== "0x") { + return args.entrypointSimulationContract + } + } + const walletClient = createWalletClient({ transport: http(args.rpcUrl), account: utilityPrivateKey From 0c5e7c279412d68fbbf5d1211adf27368ca5f9bc Mon Sep 17 00:00:00 2001 From: Garvit Khatri Date: Sun, 8 Dec 2024 23:49:26 +0000 Subject: [PATCH 2/2] Don't crash pods --- src/executor/senderManager.ts | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/src/executor/senderManager.ts b/src/executor/senderManager.ts index 279c2015..73103f69 100644 --- a/src/executor/senderManager.ts +++ b/src/executor/senderManager.ts @@ -127,13 +127,14 @@ export class SenderManager { }, "utility wallet has insufficient balance to refill wallets" ) - throw new Error( - `utility wallet ${ - this.utilityAccount.address - } has insufficient balance ${formatEther( - utilityWalletBalance - )} < ${formatEther(totalBalanceMissing)}` - ) + return + // throw new Error( + // `utility wallet ${ + // this.utilityAccount.address + // } has insufficient balance ${formatEther( + // utilityWalletBalance + // )} < ${formatEther(totalBalanceMissing)}` + // ) } if (Object.keys(balancesMissing).length > 0) {