From 8338304533949390bde95a21d480b1d013e30da2 Mon Sep 17 00:00:00 2001 From: Craigory Coppola Date: Tue, 25 Jun 2024 14:23:18 -0400 Subject: [PATCH] chore(repo): test --- .circleci/config.yml | 6 +----- nx.json | 2 +- .../project-graph/plugins/isolation/plugin-worker.ts | 11 +++++++++-- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index ba498cd4d15a28..ced0e0a694b1af 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -98,10 +98,6 @@ jobs: - browser-tools/install-chrome - run-pnpm-install: os: linux - - run: - name: Check Documentation - command: pnpm nx documentation --no-dte - no_output_timeout: 20m - run: name: Run Checks/Lint/Test/Build no_output_timeout: 60m @@ -114,7 +110,7 @@ jobs: pnpm nx run-many -t check-imports check-commit check-lock-files check-codeowners documentation --parallel=1 --no-dte & pids+=($!) - (pnpm nx affected --targets=lint,test,build --base=$NX_BASE --head=$NX_HEAD --parallel=3 && + (pnpm nx affected --targets=lint,test,build --base=$NX_BASE --head=$NX_HEAD --parallel=3 --exclude nx && pnpm nx affected --targets=e2e,e2e-ci --base=$NX_BASE --head=$NX_HEAD --parallel=1) & pids+=($!) diff --git a/nx.json b/nx.json index 4e9ad71484b5ae..24750ba2831a15 100644 --- a/nx.json +++ b/nx.json @@ -212,6 +212,6 @@ "nxCloudUrl": "https://staging.nx.app", "parallel": 1, "cacheDirectory": "/tmp/nx-cache", - "bust": 6, + "bust": 7, "defaultBase": "master" } diff --git a/packages/nx/src/project-graph/plugins/isolation/plugin-worker.ts b/packages/nx/src/project-graph/plugins/isolation/plugin-worker.ts index ed636665e021fa..0303021a83da17 100644 --- a/packages/nx/src/project-graph/plugins/isolation/plugin-worker.ts +++ b/packages/nx/src/project-graph/plugins/isolation/plugin-worker.ts @@ -132,9 +132,16 @@ const server = createServer((socket) => { server.listen(socketPath); -process.on('exit', () => { +const exitHandler = (exitCode: number) => () => { server.close(); try { unlinkSync(socketPath); } catch (e) {} -}); + process.exit(exitCode); +}; + +const events = ['SIGINT', 'SIGTERM', 'SIGQUIT', 'exit']; + +events.forEach((event) => process.once(event, exitHandler(0))); +process.once('uncaughtException', exitHandler(1)); +process.once('unhandledRejection', exitHandler(1));