From c484e50ad990ae50e99a5badc4cec60e679d68e8 Mon Sep 17 00:00:00 2001 From: saleel Date: Mon, 23 Dec 2024 23:46:49 +0400 Subject: [PATCH] fix: fix proverEnabled flag in cli-wallet (#10945) Fix in cli-wallet proving was disabled even with env `PXE_PROVER_ENABLED=1` --- yarn-project/cli-wallet/src/bin/index.ts | 16 ++++------------ 1 file changed, 4 insertions(+), 12 deletions(-) diff --git a/yarn-project/cli-wallet/src/bin/index.ts b/yarn-project/cli-wallet/src/bin/index.ts index cda770c1ae3..b7a783d6fb7 100644 --- a/yarn-project/cli-wallet/src/bin/index.ts +++ b/yarn-project/cli-wallet/src/bin/index.ts @@ -86,27 +86,19 @@ async function main() { .env('AZTEC_NODE_URL') .default(`http://${LOCALHOST}:8080`), ) - .addOption( - new Option('-b, --bb-binary-path ', 'Path to the BB binary') - .env('BB_BINARY_PATH') - .default(`$HOME/.bb/bb`), - ) - .addOption( - new Option('-w, --bb-working-directory ', 'Path to the BB working directory') - .env('BB_WORKING_DIRECTORY') - .default(`$HOME/.bb-workdir`), - ) .hook('preSubcommand', async command => { const { dataDir, remotePxe, nodeUrl } = command.optsWithGlobals(); if (!remotePxe) { debugLogger.info('Using local PXE service'); + + // Always enable proving when profiling const subcommand = command.args[0]; const isProfiling = command.args.includes('--profile'); - const enableProving = subcommand === 'simulate' && isProfiling; + const proverEnabled = subcommand === 'simulate' && isProfiling; await pxeWrapper.init(nodeUrl, join(dataDir, 'pxe'), { - proverEnabled: enableProving, + ...(proverEnabled && { proverEnabled }), // only override if we're profiling }); } db.init(AztecLmdbStore.open(dataDir));