diff --git a/.github/workflows/build-backend.yml b/.github/workflows/build-backend.yml index 38265c92..267ea01a 100644 --- a/.github/workflows/build-backend.yml +++ b/.github/workflows/build-backend.yml @@ -23,7 +23,7 @@ jobs: if: steps.cache.outputs.cache-hit != 'true' uses: actions/setup-node@v4 with: - node-version: 18.18.2 + node-version: 22 cache: "npm" cache-dependency-path: qg-api-service/package-lock.json diff --git a/.github/workflows/build-typescript-apps.yml b/.github/workflows/build-typescript-apps.yml index 3bfe5104..d51c4e9c 100644 --- a/.github/workflows/build-typescript-apps.yml +++ b/.github/workflows/build-typescript-apps.yml @@ -23,7 +23,7 @@ jobs: if: steps.cache.outputs.cache-hit != 'true' uses: actions/setup-node@v4 with: - node-version: 18 + node-version: 22 check-latest: true cache: 'npm' cache-dependency-path: yaku-apps-typescript/package-lock.json diff --git a/core-image/Dockerfile b/core-image/Dockerfile index fe098595..3707cef6 100644 --- a/core-image/Dockerfile +++ b/core-image/Dockerfile @@ -13,7 +13,7 @@ LABEL maintainer="Neutrinos GROW/PAT" LABEL description="YAKU core docker image based on Ubuntu 22.04 image" ARG DEBIAN_FRONTEND=noninteractive -ARG NODE_VERSION=18 +ARG NODE_VERSION=22 ARG USERNAME="qguser" ARG USER_UID=1001 ARG USER_GID=1000 diff --git a/qg-api-service/qg-api-service/Dockerfile b/qg-api-service/qg-api-service/Dockerfile index b683da9d..ca478670 100644 --- a/qg-api-service/qg-api-service/Dockerfile +++ b/qg-api-service/qg-api-service/Dockerfile @@ -6,7 +6,7 @@ # BUILD FOR LOCAL DEVELOPMENT ################### -ARG BASE_IMAGE_NAME="node:18-alpine" +ARG BASE_IMAGE_NAME="node:22-alpine" FROM ${BASE_IMAGE_NAME} As development @@ -21,7 +21,7 @@ RUN npm install -ws --include-workspace-root # BUILD FOR PRODUCTION ################### -ARG BASE_IMAGE_NAME="node:18-alpine" +ARG BASE_IMAGE_NAME="node:22-alpine" FROM ${BASE_IMAGE_NAME} As build @@ -46,7 +46,7 @@ USER node # PRODUCTION ################### -ARG BASE_IMAGE_NAME="node:18-alpine" +ARG BASE_IMAGE_NAME="node:22-alpine" FROM ${BASE_IMAGE_NAME} As production diff --git a/qg-api-service/scale-run-test/tsup.config.ts b/qg-api-service/scale-run-test/tsup.config.ts index e3509531..073b3453 100644 --- a/qg-api-service/scale-run-test/tsup.config.ts +++ b/qg-api-service/scale-run-test/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/qg-api-service/yaku-cli/src/handlers/environment.spec.ts b/qg-api-service/yaku-cli/src/handlers/environment.spec.ts index 21acb0b8..f57a2810 100644 --- a/qg-api-service/yaku-cli/src/handlers/environment.spec.ts +++ b/qg-api-service/yaku-cli/src/handlers/environment.spec.ts @@ -131,7 +131,7 @@ describe('loadEnvironments()', () => { // the error message must be specific to permissions expect(consoleErrorSpy).toHaveBeenCalledWith( chalk.red( - `Failed to parse '${testEnvFilePath}' as JSON: SyntaxError: Unexpected token ! in JSON at position 0`, + `Failed to parse '${testEnvFilePath}' as JSON: SyntaxError: Unexpected token '!', \"![]\" is not valid JSON`, ), ) expect(existsSyncSpy).toHaveBeenCalledWith(testEnvFilePath) diff --git a/qg-api-service/yaku-cli/src/handlers/login.spec.ts b/qg-api-service/yaku-cli/src/handlers/login.spec.ts index 8ba0fd4c..a6a07f35 100644 --- a/qg-api-service/yaku-cli/src/handlers/login.spec.ts +++ b/qg-api-service/yaku-cli/src/handlers/login.spec.ts @@ -78,7 +78,7 @@ describe('login()', () => { expect(consoleErrorSpy).toHaveBeenCalledWith( chalk.red( - `Failed to parse '${testEnvHome}/.yakurc' as JSON: SyntaxError: Unexpected token ! in JSON at position 0`, + `Failed to parse '${testEnvHome}/.yakurc' as JSON: SyntaxError: Unexpected token '!', \"!\" is not valid JSON`, ), ) expect(consoleErrorSpy).toHaveBeenCalledWith(chalk.red('process.exit: 1')) diff --git a/qg-api-service/yaku-client-lib/tsup.config.ts b/qg-api-service/yaku-client-lib/tsup.config.ts index e3509531..073b3453 100644 --- a/qg-api-service/yaku-client-lib/tsup.config.ts +++ b/qg-api-service/yaku-client-lib/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/ado-work-items-evaluator/tsup.config.ts b/yaku-apps-typescript/apps/ado-work-items-evaluator/tsup.config.ts index 4688ae03..e16a4047 100644 --- a/yaku-apps-typescript/apps/ado-work-items-evaluator/tsup.config.ts +++ b/yaku-apps-typescript/apps/ado-work-items-evaluator/tsup.config.ts @@ -10,7 +10,7 @@ export default defineConfig({ splitting: false, sourcemap: true, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, }) diff --git a/yaku-apps-typescript/apps/ado-work-items-fetcher/tsup.config.ts b/yaku-apps-typescript/apps/ado-work-items-fetcher/tsup.config.ts index 4688ae03..e16a4047 100644 --- a/yaku-apps-typescript/apps/ado-work-items-fetcher/tsup.config.ts +++ b/yaku-apps-typescript/apps/ado-work-items-fetcher/tsup.config.ts @@ -10,7 +10,7 @@ export default defineConfig({ splitting: false, sourcemap: true, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, }) diff --git a/yaku-apps-typescript/apps/defender-for-cloud/tsup.config.ts b/yaku-apps-typescript/apps/defender-for-cloud/tsup.config.ts index e3509531..073b3453 100644 --- a/yaku-apps-typescript/apps/defender-for-cloud/tsup.config.ts +++ b/yaku-apps-typescript/apps/defender-for-cloud/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/git-fetcher/tsup.config.ts b/yaku-apps-typescript/apps/git-fetcher/tsup.config.ts index e3509531..073b3453 100644 --- a/yaku-apps-typescript/apps/git-fetcher/tsup.config.ts +++ b/yaku-apps-typescript/apps/git-fetcher/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/html-finalizer/tsup.config.ts b/yaku-apps-typescript/apps/html-finalizer/tsup.config.ts index e3509531..073b3453 100644 --- a/yaku-apps-typescript/apps/html-finalizer/tsup.config.ts +++ b/yaku-apps-typescript/apps/html-finalizer/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/jira-evaluator/tsup.config.ts b/yaku-apps-typescript/apps/jira-evaluator/tsup.config.ts index 9ec7050d..353df1d3 100644 --- a/yaku-apps-typescript/apps/jira-evaluator/tsup.config.ts +++ b/yaku-apps-typescript/apps/jira-evaluator/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ splitting: false, sourcemap: true, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, }) diff --git a/yaku-apps-typescript/apps/jira-fetcher/tsup.config.ts b/yaku-apps-typescript/apps/jira-fetcher/tsup.config.ts index 9ec7050d..353df1d3 100644 --- a/yaku-apps-typescript/apps/jira-fetcher/tsup.config.ts +++ b/yaku-apps-typescript/apps/jira-fetcher/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ splitting: false, sourcemap: true, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, }) diff --git a/yaku-apps-typescript/apps/jira-finalizer/tsup.config.ts b/yaku-apps-typescript/apps/jira-finalizer/tsup.config.ts index fa43bb5f..dbd61742 100644 --- a/yaku-apps-typescript/apps/jira-finalizer/tsup.config.ts +++ b/yaku-apps-typescript/apps/jira-finalizer/tsup.config.ts @@ -8,7 +8,7 @@ export default defineConfig({ entry: ['src/**/*.ts', 'lib/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/json-evaluator/tsup.config.ts b/yaku-apps-typescript/apps/json-evaluator/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/apps/json-evaluator/tsup.config.ts +++ b/yaku-apps-typescript/apps/json-evaluator/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/manual-answer-evaluator/tsup.config.ts b/yaku-apps-typescript/apps/manual-answer-evaluator/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/apps/manual-answer-evaluator/tsup.config.ts +++ b/yaku-apps-typescript/apps/manual-answer-evaluator/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/mend-fetcher/tsup.config.ts b/yaku-apps-typescript/apps/mend-fetcher/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/apps/mend-fetcher/tsup.config.ts +++ b/yaku-apps-typescript/apps/mend-fetcher/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/smb-fetcher/tsup.config.ts b/yaku-apps-typescript/apps/smb-fetcher/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/apps/smb-fetcher/tsup.config.ts +++ b/yaku-apps-typescript/apps/smb-fetcher/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/apps/sonarqube/test/unit/commands/fetch/project-status.spec.ts b/yaku-apps-typescript/apps/sonarqube/test/unit/commands/fetch/project-status.spec.ts index be9b2de6..fe81d0de 100644 --- a/yaku-apps-typescript/apps/sonarqube/test/unit/commands/fetch/project-status.spec.ts +++ b/yaku-apps-typescript/apps/sonarqube/test/unit/commands/fetch/project-status.spec.ts @@ -103,7 +103,7 @@ describe('getProjectStatus', async () => { undefined, ), ).rejects.toThrowError( - 'Could not parse sonarqube response as JSON, Unexpected token s in JSON at position 0', + `Could not parse sonarqube response as JSON, Unexpected token 's', "some invalid json" is not valid JSON`, ) }) }) diff --git a/yaku-apps-typescript/apps/sonarqube/test/unit/fetch/project-status.spec.ts b/yaku-apps-typescript/apps/sonarqube/test/unit/fetch/project-status.spec.ts index 2433f2f1..260d4986 100644 --- a/yaku-apps-typescript/apps/sonarqube/test/unit/fetch/project-status.spec.ts +++ b/yaku-apps-typescript/apps/sonarqube/test/unit/fetch/project-status.spec.ts @@ -103,7 +103,7 @@ describe('getProjectStatus', async () => { undefined, ), ).rejects.toThrowError( - 'Could not parse sonarqube response as JSON, Unexpected token s in JSON at position 0', + `Could not parse sonarqube response as JSON, Unexpected token 's', "some invalid json" is not valid JSON`, ) }) }) diff --git a/yaku-apps-typescript/apps/sonarqube/tsup.config.ts b/yaku-apps-typescript/apps/sonarqube/tsup.config.ts index 9ec7050d..353df1d3 100644 --- a/yaku-apps-typescript/apps/sonarqube/tsup.config.ts +++ b/yaku-apps-typescript/apps/sonarqube/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ splitting: false, sourcemap: true, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, }) diff --git a/yaku-apps-typescript/packages/autopilot-utils/tsup.config.ts b/yaku-apps-typescript/packages/autopilot-utils/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/packages/autopilot-utils/tsup.config.ts +++ b/yaku-apps-typescript/packages/autopilot-utils/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/packages/issue-validators/tsup.config.ts b/yaku-apps-typescript/packages/issue-validators/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/packages/issue-validators/tsup.config.ts +++ b/yaku-apps-typescript/packages/issue-validators/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/packages/json-evaluator-lib/tests/read-json.spec.ts b/yaku-apps-typescript/packages/json-evaluator-lib/tests/read-json.spec.ts index ed4d83a5..655ee4a2 100644 --- a/yaku-apps-typescript/packages/json-evaluator-lib/tests/read-json.spec.ts +++ b/yaku-apps-typescript/packages/json-evaluator-lib/tests/read-json.spec.ts @@ -42,7 +42,7 @@ describe('readJson', () => { vi.mocked(readFile).mockResolvedValueOnce('invalid json') await expect(readJson('./invalid.json')).rejects.toThrow( - 'File ./invalid.json could not be parsed, failed with error: SyntaxError: Unexpected token i in JSON at position 0', + `File ./invalid.json could not be parsed, failed with error: SyntaxError: Unexpected token 'i', "invalid json" is not valid JSON`, ) }) diff --git a/yaku-apps-typescript/packages/json-evaluator-lib/tsup.config.ts b/yaku-apps-typescript/packages/json-evaluator-lib/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/packages/json-evaluator-lib/tsup.config.ts +++ b/yaku-apps-typescript/packages/json-evaluator-lib/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/packages/log-utils/tsup.config.ts b/yaku-apps-typescript/packages/log-utils/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/packages/log-utils/tsup.config.ts +++ b/yaku-apps-typescript/packages/log-utils/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true, diff --git a/yaku-apps-typescript/packages/markdown-utils/tsup.config.ts b/yaku-apps-typescript/packages/markdown-utils/tsup.config.ts index df26b5b2..91e0f0b9 100644 --- a/yaku-apps-typescript/packages/markdown-utils/tsup.config.ts +++ b/yaku-apps-typescript/packages/markdown-utils/tsup.config.ts @@ -9,7 +9,7 @@ export default defineConfig({ entry: ['src/**/*.ts'], splitting: false, clean: true, - target: 'node18', + target: 'node22', format: ['esm'], bundle: false, sourcemap: true,