Describe the bug
There was a recent pr merged with vite package bump.
It is causing error when trying to start frontend.
Steps to reproduce
1.Checkout the latest code
2.Run pnpm nx start webapp or pnpm saas up
System Info
System:
OS: Linux 6.8 Ubuntu 24.04.1 LTS 24.04.1 LTS (Noble Numbat)
CPU: (8) x64 Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz
Memory: 1.38 GB / 7.52 GB
Container: Yes
Shell: 5.2.21 - /bin/bash
Binaries:
Node: 22.13.1 - ~/.nvm/versions/node/v22.13.1/bin/node
npm: 10.9.2 - ~/.nvm/versions/node/v22.13.1/bin/npm
pnpm: 9.1.0 - ~/.local/share/pnpm/pnpm
npmPackages:
@apollo/client: ^3.9.6 => 3.10.4
@apollo/rover: ^0.19.1 => 0.19.1
@aws-sdk/client-cloudformation: ^3.577.0 => 3.577.0
@aws-sdk/client-codebuild: ^3.579.0 => 3.579.0
@aws-sdk/client-ecr: ^3.577.0 => 3.577.0
@aws-sdk/client-ecs: ^3.577.0 => 3.577.0
@aws-sdk/client-iam: ^3.577.0 => 3.577.0
@aws-sdk/client-lambda: ^3.577.0 => 3.577.0
@aws-sdk/client-s3: ^3.577.0 => 3.577.0
@aws-sdk/client-ses: ^3.577.0 => 3.577.0
@aws-sdk/client-sfn: ^3.577.0 => 3.577.0
@aws-sdk/client-sts: ^3.577.0 => 3.577.0
@babel/preset-react: ^7.24.1 => 7.24.1
@eslint/compat: ^1.0.1 => 1.0.1
@eslint/eslintrc: ^2.1.1 => 2.1.4
@graphql-codegen/cli: ^5.0.0 => 5.0.0
@graphql-typed-document-node/core: ^3.2.0 => 3.2.0
@iconify-icons/ion: ^1.2.10 => 1.2.10
@iconify/react: ^4.1.1 => 4.1.1
@nx/devkit: 19.0.1 => 19.0.1
@nx/eslint: 19.0.1 => 19.0.1
@nx/eslint-plugin: 19.0.1 => 19.0.1
@nx/jest: 19.0.1 => 19.0.1
@nx/js: 19.0.1 => 19.0.1
@nx/node: 19.0.1 => 19.0.1
@nx/plugin: 19.0.1 => 19.0.1
@nx/react: 19.0.1 => 19.0.1
@nx/web: 19.0.1 => 19.0.1
@nx/webpack: 19.0.1 => 19.0.1
@sb/cli: workspace:* => 4.1.1
@sb/core: workspace:* => 4.1.1
@sentry/react: ^8.2.1 => 8.2.1
@storybook/addon-actions: ^8.0.9 => 8.0.9
@storybook/react: ^8.0.9 => 8.0.9
@supercharge/strings: ^2.0.0 => 2.0.0
@svgr/webpack: ^8.1.0 => 8.1.0
@tailwindcss/typography: ^0.5.13 => 0.5.13
@testing-library/dom: 10.1.0 => 10.1.0
@testing-library/jest-dom: ^6.4.5 => 6.4.5
@testing-library/react: 15.0.7 => 15.0.7
@testing-library/react-hooks: ^8.0.1 => 8.0.1
@testing-library/user-event: ^14.5.2 => 14.5.2
@trivago/prettier-plugin-sort-imports: ^4.3.0 => 4.3.0
@types/gtag.js: ^0.0.19 => 0.0.19
@types/jest: ^29.5.12 => 29.5.12
@types/node: 20.12.12 => 20.12.12
@types/ramda: ^0.28.25 => 0.28.25
@types/react: ^18.3.3 => 18.3.3
@types/react-dom: ^18.3.0 => 18.3.0
@types/react-router: ^5.1.20 => 5.1.20
@types/react-router-dom: 5.3.3 => 5.3.3
@types/react-test-renderer: ^18.3.0 => 18.3.0
@typescript-eslint/eslint-plugin: 7.10.0 => 7.10.0
@typescript-eslint/parser: 7.10.0 => 7.10.0
@typescript-eslint/scope-manager: 7.10.0 => 7.10.0
@vitejs/plugin-react: ^4.3.4 => 4.3.4
aws-cdk: ^2.177.0 => 2.177.0
aws-cdk-lib: ^2.177.0 => 2.177.0
babel-jest: 29.7.0 => 29.7.0
constructs: ^10.3.0 => 10.3.0
esbuild: 0.21.3 => 0.21.3
eslint: 9.3.0 => 9.3.0
eslint-config-prettier: 9.1.0 => 9.1.0
eslint-import-resolver-typescript: ^3.6.1 => 3.6.1
eslint-plugin-formatjs: ^4.13.3 => 4.13.3
eslint-plugin-import: 2.29.1 => 2.29.1
eslint-plugin-jsx-a11y: ^6.8.0 => 6.8.0
eslint-plugin-react: 7.34.1 => 7.34.1
eslint-plugin-react-hooks: 4.6.2 => 4.6.2
eslint-plugin-testing-library: ^6.2.2 => 6.2.2
graphql: ^16.8.1 => 16.8.1
husky: ^9.0.11 => 9.0.11
jest: 29.7.0 => 29.7.0
jest-environment-jsdom: 29.7.0 => 29.7.0
jest-matcher-utils: ^29.7.0 => 29.7.0
jest-watch-typeahead: ^2.2.2 => 2.2.2
lint-staged: ^15.2.2 => 15.2.2
nx: 19.0.1 => 19.0.1
nx-cloud: 18.0.1 => 18.0.1
plop: ^4.0.1 => 4.0.1
prettier: ^3.2.5 => 3.2.5
prettier-plugin-tailwindcss: ^0.5.14 => 0.5.14
ramda: ^0.28.0 => 0.28.0
react: 18.3.1 => 18.3.1
react-dom: 18.3.1 => 18.3.1
react-helmet-async: ^1.3.0 => 1.3.0
react-hook-form: ^7.48.2 => 7.48.2
react-intl: ^6.5.5 => 6.5.5
react-loading-skeleton: ^3.3.1 => 3.3.1
react-markdown: ^8.0.7 => 8.0.7
react-router: 6.29.0 => 6.29.0
react-router-dom: 6.29.0 => 6.29.0
regenerator-runtime: ^0.14.1 => 0.14.1
styled-components: 6.1.11 => 6.1.11
tailwindcss: ^3.4.3 => 3.4.3
tailwindcss-animate: ^1.0.7 => 1.0.7
ts-jest: 29.1.3 => 29.1.3
ts-node: 10.9.2 => 10.9.2
tsconfig-paths: ^4.2.0 => 4.2.0
tslib: ^2.6.2 => 2.6.2
typescript: 5.4.5 => 5.4.5
vite: ^5.4.14 => 5.4.14
vite-plugin-eslint: ^1.8.1 => 1.8.1
vite-plugin-svgr: ^4.3.0 => 4.3.0
vite-tsconfig-paths: ^4.3.2 => 4.3.2
Logs
pnpm nx start:app
nx run webapp:setup [existing outputs match the cache, left as is]
NX Falling back to ts-node for local typescript execution. This may be a little slower.
- To fix this, ensure @swc-node/register and @swc/core have been installed
nx run webapp:"start:app"
pnpm vite
pnpm nx run webapp:graphql:generate-types:watch
node:internal/modules/cjs/loader:1247
throw err;
^
Error: Cannot find module '/home/sk/novado-saas/saas-boilerplate/node_modules/.pnpm/vite@5.4.14_@types+node@22.13.1_less@4.1.3_sass@1.84.0_stylus@0.59.0_terser@5.38.1/node_modules/vite/bin/vite.js'
at Function._resolveFilename (node:internal/modules/cjs/loader:1244:15)
at Function._load (node:internal/modules/cjs/loader:1070:27)
at TracingChannel.traceSync (node:diagnostics_channel:322:14)
at wrapModuleLoad (node:internal/modules/cjs/loader:217:24)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:170:5)
at node:internal/main/run_main_module:36:49 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v22.13.1
nx run webapp:graphql:generate-types:watch
pnpm nx run webapp-api-client:graphql:generate-types:watch
nx run webapp-api-client:graphql:generate-types:watch
pnpm run graphql-codegen -w -c ./graphql/codegen.ts
@sb/webapp-api-client@4.1.1 graphql-codegen /home/sk/novado-saas/saas-boilerplate/packages/webapp-libs/webapp-api-client
graphql-codegen "-w" "-c" "./graphql/codegen.ts"
(node:469537) [DEP0040] DeprecationWarning: The punycode module is deprecated. Please use a userland alternative instead.
(Use node --trace-deprecation ... to show where the warning was created)
[STARTED] Parse Configuration
[SUCCESS] Parse Configuration
[STARTED] Generate outputs
[STARTED] Generate to src/graphql/__generated/gql/
[STARTED] Load GraphQL schemas
[SUCCESS] Load GraphQL schemas
[STARTED] Load GraphQL documents
[SUCCESS] Load GraphQL documents
[STARTED] Generate
[SUCCESS] Generate
[SUCCESS] Generate to src/graphql/__generated/gql/
[SUCCESS] Generate outputs
Parcel watcher not found. To use this feature, please make sure to provide @parcel/watcher as a peer dependency.
NX Successfully ran target graphql for project webapp-api-client
NX Successfully ran target graphql for project webapp
Warning: command "pnpm vite" exited with non-zero status code
————————————————————————————————————————————————————————————————————————————————————————————————————
NX Ran target start:app for project webapp and 1 task(s) they depend on (8s)
✖ 1/2 failed
✔ 1/2 succeeded [1 read from cache]
ELIFECYCLE Command failed with exit code 1.
————————————————————————————————————————————————————————————————————————————————————————————————————
NX Running target start for project webapp failed
Failed tasks:
Validations
Describe the bug
There was a recent pr merged with vite package bump.
It is causing error when trying to start frontend.
Steps to reproduce
1.Checkout the latest code
2.Run
pnpm nx start webapporpnpm saas upSystem Info
System: OS: Linux 6.8 Ubuntu 24.04.1 LTS 24.04.1 LTS (Noble Numbat) CPU: (8) x64 Intel(R) Core(TM) i7-1065G7 CPU @ 1.30GHz Memory: 1.38 GB / 7.52 GB Container: Yes Shell: 5.2.21 - /bin/bash Binaries: Node: 22.13.1 - ~/.nvm/versions/node/v22.13.1/bin/node npm: 10.9.2 - ~/.nvm/versions/node/v22.13.1/bin/npm pnpm: 9.1.0 - ~/.local/share/pnpm/pnpm npmPackages: @apollo/client: ^3.9.6 => 3.10.4 @apollo/rover: ^0.19.1 => 0.19.1 @aws-sdk/client-cloudformation: ^3.577.0 => 3.577.0 @aws-sdk/client-codebuild: ^3.579.0 => 3.579.0 @aws-sdk/client-ecr: ^3.577.0 => 3.577.0 @aws-sdk/client-ecs: ^3.577.0 => 3.577.0 @aws-sdk/client-iam: ^3.577.0 => 3.577.0 @aws-sdk/client-lambda: ^3.577.0 => 3.577.0 @aws-sdk/client-s3: ^3.577.0 => 3.577.0 @aws-sdk/client-ses: ^3.577.0 => 3.577.0 @aws-sdk/client-sfn: ^3.577.0 => 3.577.0 @aws-sdk/client-sts: ^3.577.0 => 3.577.0 @babel/preset-react: ^7.24.1 => 7.24.1 @eslint/compat: ^1.0.1 => 1.0.1 @eslint/eslintrc: ^2.1.1 => 2.1.4 @graphql-codegen/cli: ^5.0.0 => 5.0.0 @graphql-typed-document-node/core: ^3.2.0 => 3.2.0 @iconify-icons/ion: ^1.2.10 => 1.2.10 @iconify/react: ^4.1.1 => 4.1.1 @nx/devkit: 19.0.1 => 19.0.1 @nx/eslint: 19.0.1 => 19.0.1 @nx/eslint-plugin: 19.0.1 => 19.0.1 @nx/jest: 19.0.1 => 19.0.1 @nx/js: 19.0.1 => 19.0.1 @nx/node: 19.0.1 => 19.0.1 @nx/plugin: 19.0.1 => 19.0.1 @nx/react: 19.0.1 => 19.0.1 @nx/web: 19.0.1 => 19.0.1 @nx/webpack: 19.0.1 => 19.0.1 @sb/cli: workspace:* => 4.1.1 @sb/core: workspace:* => 4.1.1 @sentry/react: ^8.2.1 => 8.2.1 @storybook/addon-actions: ^8.0.9 => 8.0.9 @storybook/react: ^8.0.9 => 8.0.9 @supercharge/strings: ^2.0.0 => 2.0.0 @svgr/webpack: ^8.1.0 => 8.1.0 @tailwindcss/typography: ^0.5.13 => 0.5.13 @testing-library/dom: 10.1.0 => 10.1.0 @testing-library/jest-dom: ^6.4.5 => 6.4.5 @testing-library/react: 15.0.7 => 15.0.7 @testing-library/react-hooks: ^8.0.1 => 8.0.1 @testing-library/user-event: ^14.5.2 => 14.5.2 @trivago/prettier-plugin-sort-imports: ^4.3.0 => 4.3.0 @types/gtag.js: ^0.0.19 => 0.0.19 @types/jest: ^29.5.12 => 29.5.12 @types/node: 20.12.12 => 20.12.12 @types/ramda: ^0.28.25 => 0.28.25 @types/react: ^18.3.3 => 18.3.3 @types/react-dom: ^18.3.0 => 18.3.0 @types/react-router: ^5.1.20 => 5.1.20 @types/react-router-dom: 5.3.3 => 5.3.3 @types/react-test-renderer: ^18.3.0 => 18.3.0 @typescript-eslint/eslint-plugin: 7.10.0 => 7.10.0 @typescript-eslint/parser: 7.10.0 => 7.10.0 @typescript-eslint/scope-manager: 7.10.0 => 7.10.0 @vitejs/plugin-react: ^4.3.4 => 4.3.4 aws-cdk: ^2.177.0 => 2.177.0 aws-cdk-lib: ^2.177.0 => 2.177.0 babel-jest: 29.7.0 => 29.7.0 constructs: ^10.3.0 => 10.3.0 esbuild: 0.21.3 => 0.21.3 eslint: 9.3.0 => 9.3.0 eslint-config-prettier: 9.1.0 => 9.1.0 eslint-import-resolver-typescript: ^3.6.1 => 3.6.1 eslint-plugin-formatjs: ^4.13.3 => 4.13.3 eslint-plugin-import: 2.29.1 => 2.29.1 eslint-plugin-jsx-a11y: ^6.8.0 => 6.8.0 eslint-plugin-react: 7.34.1 => 7.34.1 eslint-plugin-react-hooks: 4.6.2 => 4.6.2 eslint-plugin-testing-library: ^6.2.2 => 6.2.2 graphql: ^16.8.1 => 16.8.1 husky: ^9.0.11 => 9.0.11 jest: 29.7.0 => 29.7.0 jest-environment-jsdom: 29.7.0 => 29.7.0 jest-matcher-utils: ^29.7.0 => 29.7.0 jest-watch-typeahead: ^2.2.2 => 2.2.2 lint-staged: ^15.2.2 => 15.2.2 nx: 19.0.1 => 19.0.1 nx-cloud: 18.0.1 => 18.0.1 plop: ^4.0.1 => 4.0.1 prettier: ^3.2.5 => 3.2.5 prettier-plugin-tailwindcss: ^0.5.14 => 0.5.14 ramda: ^0.28.0 => 0.28.0 react: 18.3.1 => 18.3.1 react-dom: 18.3.1 => 18.3.1 react-helmet-async: ^1.3.0 => 1.3.0 react-hook-form: ^7.48.2 => 7.48.2 react-intl: ^6.5.5 => 6.5.5 react-loading-skeleton: ^3.3.1 => 3.3.1 react-markdown: ^8.0.7 => 8.0.7 react-router: 6.29.0 => 6.29.0 react-router-dom: 6.29.0 => 6.29.0 regenerator-runtime: ^0.14.1 => 0.14.1 styled-components: 6.1.11 => 6.1.11 tailwindcss: ^3.4.3 => 3.4.3 tailwindcss-animate: ^1.0.7 => 1.0.7 ts-jest: 29.1.3 => 29.1.3 ts-node: 10.9.2 => 10.9.2 tsconfig-paths: ^4.2.0 => 4.2.0 tslib: ^2.6.2 => 2.6.2 typescript: 5.4.5 => 5.4.5 vite: ^5.4.14 => 5.4.14 vite-plugin-eslint: ^1.8.1 => 1.8.1 vite-plugin-svgr: ^4.3.0 => 4.3.0 vite-tsconfig-paths: ^4.3.2 => 4.3.2Logs
NX Falling back to ts-node for local typescript execution. This may be a little slower.
node:internal/modules/cjs/loader:1247
throw err;
^
Error: Cannot find module '/home/sk/novado-saas/saas-boilerplate/node_modules/.pnpm/vite@5.4.14_@types+node@22.13.1_less@4.1.3_sass@1.84.0_stylus@0.59.0_terser@5.38.1/node_modules/vite/bin/vite.js'
at Function._resolveFilename (node:internal/modules/cjs/loader:1244:15)
at Function._load (node:internal/modules/cjs/loader:1070:27)
at TracingChannel.traceSync (node:diagnostics_channel:322:14)
at wrapModuleLoad (node:internal/modules/cjs/loader:217:24)
at Function.executeUserEntryPoint [as runMain] (node:internal/modules/run_main:170:5)
at node:internal/main/run_main_module:36:49 {
code: 'MODULE_NOT_FOUND',
requireStack: []
}
Node.js v22.13.1
(node:469537) [DEP0040] DeprecationWarning: The
punycodemodule is deprecated. Please use a userland alternative instead.(Use
node --trace-deprecation ...to show where the warning was created)[STARTED] Parse Configuration
[SUCCESS] Parse Configuration
[STARTED] Generate outputs
[STARTED] Generate to src/graphql/__generated/gql/
[STARTED] Load GraphQL schemas
[SUCCESS] Load GraphQL schemas
[STARTED] Load GraphQL documents
[SUCCESS] Load GraphQL documents
[STARTED] Generate
[SUCCESS] Generate
[SUCCESS] Generate to src/graphql/__generated/gql/
[SUCCESS] Generate outputs
Parcel watcher not found. To use this feature, please make sure to provide @parcel/watcher as a peer dependency.
NX Successfully ran target graphql for project webapp-api-client
NX Successfully ran target graphql for project webapp
Warning: command "pnpm vite" exited with non-zero status code
————————————————————————————————————————————————————————————————————————————————————————————————————
NX Ran target start:app for project webapp and 1 task(s) they depend on (8s)
✖ 1/2 failed
✔ 1/2 succeeded [1 read from cache]
ELIFECYCLE Command failed with exit code 1.
————————————————————————————————————————————————————————————————————————————————————————————————————
NX Running target start for project webapp failed
Failed tasks:
Validations