[GH-ISSUE #2717] [bug]: windows build failed. #884

Closed
opened 2026-03-16 17:33:39 +03:00 by kerem · 4 comments
Owner

Originally created by @liudonghua123 on GitHub (Oct 1, 2022).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/2717

Is there an existing issue for this?

  • I have searched the existing issues

Current behavior

I tried to run pnpm run generate on windows 11, use node 18.4.0, npm 8.5.1, pnpm 7.12.2, however, I got [vite-plugin-pwa] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages │ error during build errors.

D:\code\rust\hoppscotch-app>cd hoppscotch\

D:\code\rust\hoppscotch-app\hoppscotch>pnpm install
Scope: all 6 workspace projects
Lockfile is up to date, resolution step is skipped
Already up to date
packages/codemirror-lang-graphql prepare$ rollup -c
└─ Running...
packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl
│ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-
│ > vite build
│ vite v3.1.0 building for production...
│ transforming...
│ ✓ 287 modules transformed.
│
└─ Running...
packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl
│ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-
│ > vite build
│ vite v3.1.0 building for production...
│ transforming...
│ ✓ 287 modules transformed.d
│ src/index.js → dist/index.cjs, ./dist...
└─ Running...
packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl
│ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-  
│ > vite build
│ vite v3.1.0 building for production...
│ transforming...
│ ✓ 287 modules transformed.d
│ created dist/index.cjs, ./dist in 3.4s
└─ Running...
packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl
│ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-  
│ > vite build
│ vite v3.1.0 building for production...
│ transforming...
│ ✓ 287 modules transformed.d
└─ Done in 44.1sks...
│ dist/hoppscotch-data.js   46.29 KiB / gzip: 13.39 KiB
│ dist/hoppscotch-data.cjs   34.29 KiB / gzip: 12.04 KiB
│ > @hoppscotch/data@0.4.3 build:decl D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-  
│ > tsc --project tsconfig.decl.json
└─ Done in 31.8s
. prepare$ husky install
│ husky - Git hooks installed
└─ Done in 403ms
packages/hoppscotch-js-sandbox postinstall$ pnpm run build
│ > @hoppscotch/js-sandbox@2.1.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch
│ > pnpm exec tsup
[1 lines collapsed]
│ CLI Using tsconfig: tsconfig.json
│2CLI tsup v5.12.9
│ CLI Building entry: src/index.tsust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts
│3CLI Using tsconfig: tsconfig.json
│ CLI Using tsconfig: tsconfig.json
│4CLI tsup v5.12.9
│ CLI tsup v5.12.9                                                                                 
│5CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts
│ CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts  
│6CLI Target: node12                                                                               
│ CLI Target: node12
│7CLI Cleaning output folder                                                                       
│ CLI Cleaning output folder
│8ESM Build start
│ ESM Build start
│9CJS Build startccess in 83ms
│ CJS Build startccess in 83ms
│ CJS ⚡️ Build success in 83ms
│ DTS Build start
│ ESM ⚡️ Build success in 3939ms
│ ESM lib\index.mjs     18.97 KB
│ ESM lib\index.mjs.map 38.94 KB
│ CJS lib\index.js     20.05 KB
│ CJS lib\index.js.map 38.94 KBs
│ DTS ⚡️ Build success in 5587ms
└─ Done in 18.6sd.ts 2.73 KB
packages/hoppscotch-app postinstall$ pnpm run gql-codegen
│ > hoppscotch-app@3.0.0 gql-codegen D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-a
│ > graphql-codegen --config gql-codegen.yml
[1 lines collapsed][SUCCESS] Parse Configuration
│2[STARTED] Generate outputs
│ [STARTED] Parse Configuration
│3[SUCCESS] Parse Configurations
│ [SUCCESS] Parse Configuration
│4[STARTED] Generate outputs
│ [STARTED] Generate outputs
│5[STARTED] Generate src/helpers/backend/graphql.ts
│ [STARTED] Generate src/helpers/backend/graphql.ts
│6[STARTED] Load GraphQL schemas
│ [STARTED] Load GraphQL schemas                                                                   
│7(node:16480) ExperimentalWarning: The Fetch API is an experimental feature. This feature could 
│ (node:16480) ExperimentalWarning: The Fetch API is an experimental feature. This feature could   
│8(Use `node --trace-warnings ...` to show where the warning was created)(Use `node --trace-warnings ...` to show where the warning was created)                          
│9[SUCCESS] Load GraphQL schemas                                                                   
│ [SUCCESS] Load GraphQL schemas                                                                   
[10 lines collapsed]phQL documents                                                                 
│ [STARTED] Load GraphQL documents                                                                 
│ 1SUCCESS] Load GraphQL documents                                                                 
│ [SUCCESS] Load GraphQL documents                                                                 
│ 2STARTED] Generate                                                                               
│ [STARTED] Generate
│ 3SUCCESS] Generate src/helpers/backend/graphql.tshema.json                                       
│ [SUCCESS] Generate src/helpers/backend/graphql.tshema.json                                       
│ 4SUCCESS] Generate src/helpers/backend/graphql.tshema.json                                       
│ [SUCCESS] Generate src/helpers/backend/graphql.tshema.json
│ [STARTED] Generate src/helpers/backend/backend-schema.json
│ [STARTED] Load GraphQL schemas                                                                   
│ [SUCCESS] Load GraphQL schemasts
│ [STARTED] Load GraphQL documents
│ [SUCCESS] Load GraphQL documents
│ [STARTED] Generate                                                                               
│ [SUCCESS] Generate src/helpers/backend/backend-schema.json
│ [SUCCESS] Generate src/helpers/backend/backend-schema.json
└─ Done in 40.8srate outputs

D:\code\rust\hoppscotch-app\hoppscotch>pnpm run generate

> hoppscotch-app@3.0.0 generate D:\code\rust\hoppscotch-app\hoppscotch
> pnpm -r do-build-prod

Scope: 5 of 6 workspace projects
packages/hoppscotch-js-sandbox do-build-prod$ pnpm run build
│ > @hoppscotch/js-sandbox@2.1.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch
│ > pnpm exec tsup
[1 lines collapsed]
│ CLI Using tsconfig: tsconfig.json
│2CLI tsup v5.12.9
│ CLI Building entry: src/index.tsust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts
│3CLI Using tsconfig: tsconfig.json
│ CLI Using tsconfig: tsconfig.json
│4CLI tsup v5.12.9
│ CLI tsup v5.12.9                                                                                 
│5CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts
│ CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts  
│6CLI Target: node12
│ CLI Target: node12                                                                               
│7CLI Cleaning output folder
│ CLI Cleaning output folder                                                                       
│8ESM Build start
│ ESM Build start
│9CJS Build startccess in 32mssB
│ CJS Build startccess in 32mssB
│ CJS ⚡️ Build success in 32mssB
│ ESM ⚡️ Build success in 191msB
│ ESM lib\index.mjs     18.97 KB
│ ESM lib\index.mjs.map 38.94 KB
│ CJS lib\index.js     20.05 KB
│ CJS lib\index.js.map 38.94 KB
│ DTS Build start
│ DTS ⚡️ Build success in 2474ms
└─ Done in 4.7s.d.ts 2.73 KB
packages/hoppscotch-app do-build-prod$ pnpm run build
│ > hoppscotch-app@3.0.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app
│ > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build
[1 lines collapsed]                                                                                
│ transforming...
│2✓ 830 modules transformed.
│ vite v3.1.0 building for production...                                                           
│ > hoppscotch-app@3.0.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app
│ > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build
│ vite v3.1.0 building for production...oppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p  
│ transforming...
│ ✓ 830 modules transformed.
│ [vite-plugin-pwa] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages  
│ error during build:
│ TypeError: Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (impor  
│     at removeMaybeSuffix (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin
│     at D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.3.
│     at Array.map (<anonymous>)
│     at getSitemapLinks (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p
│     at generateSitemap (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p
│     at Object.onRoutesGenerated (D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app
│     at computeVueRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-
│     at resolveVueRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-
│     at Object.resolveRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plu
│     at PageContext.resolveRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vit
│  ELIFECYCLE  Command failed with exit code 1.
└─ Failed in 1m 3.9s
D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app:
 ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  hoppscotch-app@3.0.0 do-build-prod: `pnpm run build`
Exit status 1
 ELIFECYCLE  Command failed with exit code 1.

D:\code\rust\hoppscotch-app\hoppscotch>
D:\code\rust\hoppscotch-app\hoppscotch>node -v
v18.4.0

D:\code\rust\hoppscotch-app\hoppscotch>npm -v
8.5.1

D:\code\rust\hoppscotch-app\hoppscotch>pnpm --version
7.12.2

D:\code\rust\hoppscotch-app\hoppscotch>
D:\code\rust\hoppscotch-app\hoppscotch>pnpm run dev

> hoppscotch-app@3.0.0 dev D:\code\rust\hoppscotch-app\hoppscotch
> pnpm -r do-dev

Scope: 5 of 6 workspace projects
packages/hoppscotch-app do-dev$ pnpm run dev
[593 lines collapsed][dev:vite       ][dev:vite       ]     1007 | export const TeamRequestAddedDocument = {"kind":"Document","defini  
│ [dev:vite       ]     1008 | export const TeamRequestDeletedDocument = {"kind":"Document","defi  
│ [dev:vite       ]   > 1009 | export const TeamRequestUpdatedDocument = {"kind":"Document","defi  
│ [dev:vite       ]          |
│ [dev:vite       ]     1010 | export type WithTypename<T extends { __typename?: any }> = Partial  
│ [dev:vite       ]     1011 |
│ [dev:vite       ]     1012 | export type GraphCacheKeysConfig = {
│ [dev:vite       ]
│ [dev:vite       ] [ESLint] Found 51 errors and 0 warning
└─ Running...

# No response ...

Steps to reproduce

  1. git clone git@github.com:hoppscotch/hoppscotch.git
  2. cd hoppscotch
  3. pnpm install
  4. pnpm run generate

Environment

Release

Version

Local

Originally created by @liudonghua123 on GitHub (Oct 1, 2022). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/2717 ### Is there an existing issue for this? - [X] I have searched the existing issues ### Current behavior I tried to run `pnpm run generate` on windows 11, use node 18.4.0, npm 8.5.1, pnpm 7.12.2, however, I got `[vite-plugin-pwa] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages │ error during build` errors. ```shell D:\code\rust\hoppscotch-app>cd hoppscotch\ D:\code\rust\hoppscotch-app\hoppscotch>pnpm install Scope: all 6 workspace projects Lockfile is up to date, resolution step is skipped Already up to date packages/codemirror-lang-graphql prepare$ rollup -c └─ Running... packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl │ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch- │ > vite build │ vite v3.1.0 building for production... │ transforming... │ ✓ 287 modules transformed. │ └─ Running... packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl │ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch- │ > vite build │ vite v3.1.0 building for production... │ transforming... │ ✓ 287 modules transformed.d │ src/index.js → dist/index.cjs, ./dist... └─ Running... packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl │ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch- │ > vite build │ vite v3.1.0 building for production... │ transforming... │ ✓ 287 modules transformed.d │ created dist/index.cjs, ./dist in 3.4s └─ Running... packages/hoppscotch-data prepare$ pnpm run build:code && pnpm run build:decl │ > @hoppscotch/data@0.4.3 build:code D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch- │ > vite build │ vite v3.1.0 building for production... │ transforming... │ ✓ 287 modules transformed.d └─ Done in 44.1sks... │ dist/hoppscotch-data.js 46.29 KiB / gzip: 13.39 KiB │ dist/hoppscotch-data.cjs 34.29 KiB / gzip: 12.04 KiB │ > @hoppscotch/data@0.4.3 build:decl D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch- │ > tsc --project tsconfig.decl.json └─ Done in 31.8s . prepare$ husky install │ husky - Git hooks installed └─ Done in 403ms packages/hoppscotch-js-sandbox postinstall$ pnpm run build │ > @hoppscotch/js-sandbox@2.1.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch │ > pnpm exec tsup [1 lines collapsed] │ CLI Using tsconfig: tsconfig.json │2CLI tsup v5.12.9 │ CLI Building entry: src/index.tsust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │3CLI Using tsconfig: tsconfig.json │ CLI Using tsconfig: tsconfig.json │4CLI tsup v5.12.9 │ CLI tsup v5.12.9 │5CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │ CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │6CLI Target: node12 │ CLI Target: node12 │7CLI Cleaning output folder │ CLI Cleaning output folder │8ESM Build start │ ESM Build start │9CJS Build startccess in 83ms │ CJS Build startccess in 83ms │ CJS ⚡️ Build success in 83ms │ DTS Build start │ ESM ⚡️ Build success in 3939ms │ ESM lib\index.mjs 18.97 KB │ ESM lib\index.mjs.map 38.94 KB │ CJS lib\index.js 20.05 KB │ CJS lib\index.js.map 38.94 KBs │ DTS ⚡️ Build success in 5587ms └─ Done in 18.6sd.ts 2.73 KB packages/hoppscotch-app postinstall$ pnpm run gql-codegen │ > hoppscotch-app@3.0.0 gql-codegen D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-a │ > graphql-codegen --config gql-codegen.yml [1 lines collapsed] │ [SUCCESS] Parse Configuration │2[STARTED] Generate outputs │ [STARTED] Parse Configuration │3[SUCCESS] Parse Configurations │ [SUCCESS] Parse Configuration │4[STARTED] Generate outputs │ [STARTED] Generate outputs │5[STARTED] Generate src/helpers/backend/graphql.ts │ [STARTED] Generate src/helpers/backend/graphql.ts │6[STARTED] Load GraphQL schemas │ [STARTED] Load GraphQL schemas │7(node:16480) ExperimentalWarning: The Fetch API is an experimental feature. This feature could │ (node:16480) ExperimentalWarning: The Fetch API is an experimental feature. This feature could │8(Use `node --trace-warnings ...` to show where the warning was created) │ (Use `node --trace-warnings ...` to show where the warning was created) │9[SUCCESS] Load GraphQL schemas │ [SUCCESS] Load GraphQL schemas [10 lines collapsed]phQL documents │ [STARTED] Load GraphQL documents │ 1SUCCESS] Load GraphQL documents │ [SUCCESS] Load GraphQL documents │ 2STARTED] Generate │ [STARTED] Generate │ 3SUCCESS] Generate src/helpers/backend/graphql.tshema.json │ [SUCCESS] Generate src/helpers/backend/graphql.tshema.json │ 4SUCCESS] Generate src/helpers/backend/graphql.tshema.json │ [SUCCESS] Generate src/helpers/backend/graphql.tshema.json │ [STARTED] Generate src/helpers/backend/backend-schema.json │ [STARTED] Load GraphQL schemas │ [SUCCESS] Load GraphQL schemasts │ [STARTED] Load GraphQL documents │ [SUCCESS] Load GraphQL documents │ [STARTED] Generate │ [SUCCESS] Generate src/helpers/backend/backend-schema.json │ [SUCCESS] Generate src/helpers/backend/backend-schema.json └─ Done in 40.8srate outputs D:\code\rust\hoppscotch-app\hoppscotch>pnpm run generate > hoppscotch-app@3.0.0 generate D:\code\rust\hoppscotch-app\hoppscotch > pnpm -r do-build-prod Scope: 5 of 6 workspace projects packages/hoppscotch-js-sandbox do-build-prod$ pnpm run build │ > @hoppscotch/js-sandbox@2.1.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch │ > pnpm exec tsup [1 lines collapsed] │ CLI Using tsconfig: tsconfig.json │2CLI tsup v5.12.9 │ CLI Building entry: src/index.tsust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │3CLI Using tsconfig: tsconfig.json │ CLI Using tsconfig: tsconfig.json │4CLI tsup v5.12.9 │ CLI tsup v5.12.9 │5CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │ CLI Using tsup config: D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-js-sandbox\ts │6CLI Target: node12 │ CLI Target: node12 │7CLI Cleaning output folder │ CLI Cleaning output folder │8ESM Build start │ ESM Build start │9CJS Build startccess in 32mssB │ CJS Build startccess in 32mssB │ CJS ⚡️ Build success in 32mssB │ ESM ⚡️ Build success in 191msB │ ESM lib\index.mjs 18.97 KB │ ESM lib\index.mjs.map 38.94 KB │ CJS lib\index.js 20.05 KB │ CJS lib\index.js.map 38.94 KB │ DTS Build start │ DTS ⚡️ Build success in 2474ms └─ Done in 4.7s.d.ts 2.73 KB packages/hoppscotch-app do-build-prod$ pnpm run build │ > hoppscotch-app@3.0.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app │ > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build [1 lines collapsed] │ transforming... │2✓ 830 modules transformed. │ vite v3.1.0 building for production... │ > hoppscotch-app@3.0.0 build D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app │ > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build │ vite v3.1.0 building for production...oppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p │ transforming... │ ✓ 830 modules transformed. │ [vite-plugin-pwa] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages │ error during build: │ TypeError: Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (impor │ at removeMaybeSuffix (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin │ at D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.3. │ at Array.map (<anonymous>) │ at getSitemapLinks (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p │ at generateSitemap (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin-p │ at Object.onRoutesGenerated (D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app │ at computeVueRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin- │ at resolveVueRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plugin- │ at Object.resolveRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vite-plu │ at PageContext.resolveRoutes (D:\code\rust\hoppscotch-app\hoppscotch\node_modules\.pnpm\vit │  ELIFECYCLE  Command failed with exit code 1. └─ Failed in 1m 3.9s D:\code\rust\hoppscotch-app\hoppscotch\packages\hoppscotch-app:  ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  hoppscotch-app@3.0.0 do-build-prod: `pnpm run build` Exit status 1  ELIFECYCLE  Command failed with exit code 1. D:\code\rust\hoppscotch-app\hoppscotch> D:\code\rust\hoppscotch-app\hoppscotch>node -v v18.4.0 D:\code\rust\hoppscotch-app\hoppscotch>npm -v 8.5.1 D:\code\rust\hoppscotch-app\hoppscotch>pnpm --version 7.12.2 D:\code\rust\hoppscotch-app\hoppscotch> D:\code\rust\hoppscotch-app\hoppscotch>pnpm run dev > hoppscotch-app@3.0.0 dev D:\code\rust\hoppscotch-app\hoppscotch > pnpm -r do-dev Scope: 5 of 6 workspace projects packages/hoppscotch-app do-dev$ pnpm run dev [593 lines collapsed] │ [dev:vite ] │ [dev:vite ] 1007 | export const TeamRequestAddedDocument = {"kind":"Document","defini │ [dev:vite ] 1008 | export const TeamRequestDeletedDocument = {"kind":"Document","defi │ [dev:vite ] > 1009 | export const TeamRequestUpdatedDocument = {"kind":"Document","defi │ [dev:vite ] | │ [dev:vite ] 1010 | export type WithTypename<T extends { __typename?: any }> = Partial │ [dev:vite ] 1011 | │ [dev:vite ] 1012 | export type GraphCacheKeysConfig = { │ [dev:vite ] │ [dev:vite ] [ESLint] Found 51 errors and 0 warning └─ Running... # No response ... ``` ### Steps to reproduce 1. git clone git@github.com:hoppscotch/hoppscotch.git 2. cd hoppscotch 3. pnpm install 4. pnpm run generate ### Environment Release ### Version Local
kerem 2026-03-16 17:33:39 +03:00
Author
Owner

@piraces commented on GitHub (Oct 1, 2022):

Can confirm the problem in a Windows environment with the following versions:

PS C:\Users> node -v
v16.17.0
PS C:\Users> npm -v
8.15.0
PS C:\Users> pnpm -v
7.12.2

Error when running pnpm run generate:

PS C:\DEV\hoppscotch> pnpm run generate

> hoppscotch-app@3.0.0 generate C:\DEV\hoppscotch
> pnpm -r do-build-prod

Scope: 5 of 6 workspace projects
packages/hoppscotch-js-sandbox do-build-prod$ pnpm run build
[9 lines collapsed]
 ESM Build start
 CJS  Build success in 43ms
 ESM  Build success in 165ms
 ESM lib\index.mjs     18.97 KB
 ESM lib\index.mjs.map 38.94 KB
 CJS lib\index.js     20.05 KB
 CJS lib\index.js.map 38.94 KB
 DTS Build start
 DTS  Build success in 2215ms
 DTS lib\index.d.ts 2.73 KB
└─ Done in 4s
packages/hoppscotch-app do-build-prod$ pnpm run build
 > hoppscotch-app@3.0.0 build C:\DEV\hoppscotch\packages\hoppscotch-app
 > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build
 vite v3.1.4 building for production...
 transforming...
  851 modules transformed.
 [vite-plugin-pwa:build] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (imported by src/modules/router.ts): Cannot read properties of undefined (reading 'endsWith')
 error during build:
 TypeError: Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (imported by src/modules/router.ts): Cannot read properties of undefined (reading 'endsWith')
     at removeMaybeSuffix (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3735:12)
     at C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3781:13
     at Array.map (<anonymous>)
     at getSitemapLinks (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3780:194)
     at generateSitemap (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3770:3)
     at Object.onRoutesGenerated (C:\DEV\hoppscotch\packages\hoppscotch-app\vite.config.ts:209:61)
     at computeVueRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:550:90)
     at resolveVueRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:555:29)
     at Object.resolveRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:594:14)
     at PageContext.resolveRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:938:34)
ELIFECYCLECommand failed with exit code 1.
└─ Failed in 28.1s
C:\DEV\hoppscotch\packages\hoppscotch-app:ERR_PNPM_RECURSIVE_RUN_FIRST_FAILhoppscotch-app@3.0.0 do-build-prod: `pnpm run build`
Exit status 1ELIFECYCLECommand failed with exit code 1.
<!-- gh-comment-id:1264408117 --> @piraces commented on GitHub (Oct 1, 2022): Can confirm the problem in a Windows environment with the following versions: ```pwsh PS C:\Users> node -v v16.17.0 PS C:\Users> npm -v 8.15.0 PS C:\Users> pnpm -v 7.12.2 ``` Error when running `pnpm run generate`: ```pwsh PS C:\DEV\hoppscotch> pnpm run generate > hoppscotch-app@3.0.0 generate C:\DEV\hoppscotch > pnpm -r do-build-prod Scope: 5 of 6 workspace projects packages/hoppscotch-js-sandbox do-build-prod$ pnpm run build [9 lines collapsed] │ ESM Build start │ CJS ⚡️ Build success in 43ms │ ESM ⚡️ Build success in 165ms │ ESM lib\index.mjs 18.97 KB │ ESM lib\index.mjs.map 38.94 KB │ CJS lib\index.js 20.05 KB │ CJS lib\index.js.map 38.94 KB │ DTS Build start │ DTS ⚡️ Build success in 2215ms │ DTS lib\index.d.ts 2.73 KB └─ Done in 4s packages/hoppscotch-app do-build-prod$ pnpm run build │ > hoppscotch-app@3.0.0 build C:\DEV\hoppscotch\packages\hoppscotch-app │ > node --max_old_space_size=16384 ./node_modules/vite/bin/vite.js build │ vite v3.1.4 building for production... │ transforming... │ ✓ 851 modules transformed. │ [vite-plugin-pwa:build] Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (imported by src/modules/router.ts): Cannot read properties of undefined (reading 'endsWith') │ error during build: │ TypeError: Could not load /@vite-plugin-pages/generated-pages?id=virtual:generated-pages (imported by src/modules/router.ts): Cannot read properties of undefined (reading 'endsWith') │ at removeMaybeSuffix (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3735:12) │ at C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3781:13 │ at Array.map (<anonymous>) │ at getSitemapLinks (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3780:194) │ at generateSitemap (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages-sitemap@1.4.0\node_modules\vite-plugin-pages-sitemap\dist\index.js:3770:3) │ at Object.onRoutesGenerated (C:\DEV\hoppscotch\packages\hoppscotch-app\vite.config.ts:209:61) │ at computeVueRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:550:90) │ at resolveVueRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:555:29) │ at Object.resolveRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:594:14) │ at PageContext.resolveRoutes (C:\DEV\hoppscotch\node_modules\.pnpm\vite-plugin-pages@0.26.0_vnheu5mvzzbfbuhqo4shkhdhei\node_modules\vite-plugin-pages\dist\index.js:938:34) │  ELIFECYCLE  Command failed with exit code 1. └─ Failed in 28.1s C:\DEV\hoppscotch\packages\hoppscotch-app:  ERR_PNPM_RECURSIVE_RUN_FIRST_FAIL  hoppscotch-app@3.0.0 do-build-prod: `pnpm run build` Exit status 1  ELIFECYCLE  Command failed with exit code 1. ```
Author
Owner

@piraces commented on GitHub (Oct 1, 2022):

Probably related: https://github.com/jbaubree/vite-plugin-pages-sitemap/issues/154

<!-- gh-comment-id:1264412534 --> @piraces commented on GitHub (Oct 1, 2022): Probably related: https://github.com/jbaubree/vite-plugin-pages-sitemap/issues/154
Author
Owner

@liudonghua123 commented on GitHub (Oct 2, 2022):

If I try to run pnpm run generate on linux, it's ok. Strange?

<!-- gh-comment-id:1264517420 --> @liudonghua123 commented on GitHub (Oct 2, 2022): If I try to run `pnpm run generate` on linux, it's ok. Strange?
Author
Owner

@AndrewBastin commented on GitHub (Oct 3, 2022):

Sorry for the delay with the response.

This is a known issue if you are migrating the codebase from Nuxt to Vue 3 (basically pulling code from before 8b300fab5d to after it).

To fix this issue, just update your .env file to be comply with the updated .env.example file.

<!-- gh-comment-id:1265069354 --> @AndrewBastin commented on GitHub (Oct 3, 2022): Sorry for the delay with the response. This is a known issue if you are migrating the codebase from Nuxt to Vue 3 (basically pulling code from before 8b300fab5d8a7fa3dd5a73e5e44d71018d0defec to after it). **To fix this issue, just update your `.env` file to be comply with the updated `.env.example` file.**
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#884
No description provided.