From b85f4d6d0e34b56090f2fe92cf30f768174d7760 Mon Sep 17 00:00:00 2001 From: pieh Date: Tue, 10 Dec 2024 13:22:22 +0100 Subject: [PATCH] chore: how about avoiding timeout forced kill --- packages/build/src/plugins/spawn.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/packages/build/src/plugins/spawn.ts b/packages/build/src/plugins/spawn.ts index e86ab1587a..6f64596b40 100644 --- a/packages/build/src/plugins/spawn.ts +++ b/packages/build/src/plugins/spawn.ts @@ -218,7 +218,9 @@ const stopPlugin = async function ({ childProcess.disconnect() } try { - childProcess.kill() + childProcess.kill('SIGTERM', { + forceKillAfterTimeout: false, + }) } catch { // In Node 22, there's a bug where attempting to kill a child process // results in an EPERM error. Ignore the error in that case.