From 09cc3dc4b604812680d737afbe95b3b8f5075487 Mon Sep 17 00:00:00 2001 From: Chris Duncan Date: Mon, 16 Jun 2025 12:49:20 -0700 Subject: [PATCH] Move server exit out of execution and into process management. --- src/bin/cli.ts | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/bin/cli.ts b/src/bin/cli.ts index 65fcc0e..09c0985 100755 --- a/src/bin/cli.ts +++ b/src/bin/cli.ts @@ -172,6 +172,8 @@ server.on('message', async (msg: Serializable): Promise => { await execute() } catch { logger.log(`Error executing ${body.action}`) + } finally { + server.kill() } } else { logger.log('CLI server failed to connect over IPC') @@ -229,5 +231,4 @@ async function execute (): Promise { } if (isBatch && !isBenchmark) console.log(results) if (process.env.NANO_POW_DEBUG || isBenchmark) console.log(stats(times)) - server.kill() } -- 2.47.3