Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pnpm workspace - Error 500: Unexpected token '||=' #15325

Closed
bgrand-ch opened this issue Nov 2, 2022 · 1 comment
Closed

Pnpm workspace - Error 500: Unexpected token '||=' #15325

bgrand-ch opened this issue Nov 2, 2022 · 1 comment

Comments

@bgrand-ch
Copy link

Environment

  • Operating System: Darwin
  • Node Version: v14.20.1
  • Nuxt Version: 3.0.0-rc.12
  • Nitro Version: 0.6.0
  • Package Manager: pnpm@7.14.1
  • Builder: vite
  • User Config: -
  • Runtime Modules: -
  • Build Modules: -

Reproduction

ℹ️ All works fine with nuxt@3.0.0-rc.11, error occur only with nuxt@3.0.0-rc.12.

  1. Create a new monorepo project.
  2. Add a single name in the package.json file of each Nuxt projects.
  3. Add pnpm-workspace.yaml to the root folder.
  4. Follow all pnpm steps on the Nuxt installation page, for each projects.
  5. Run pnpm --filter my-project-name dev -o to the root folder.
  6. Error 500: Unexpected token '||='.

Describe the bug

After "Nitro built" terminal message, there is an error 500 with the message: Unexpected token '||='.

500
Unexpected token '||='

at new Script (vm.js:102:7)
at createScript (vm.js:262:10)
at Object.runInThisContext (vm.js:310:10)
at ViteNodeRunner.directRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:245:19)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at async ViteNodeRunner.cachedRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:129:12)
at async request (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:152:16)
at async /Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/nuxt@3.0.0-rc.12/node_modules/nuxt/dist/app/composables/index.mjs:46:31
at async ViteNodeRunner.directRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:250:5)
at async ViteNodeRunner.cachedRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:129:12)

Additional context

No response

Logs

at new Script (vm.js:102:7)
at createScript (vm.js:262:10)
at Object.runInThisContext (vm.js:310:10)
at ViteNodeRunner.directRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:245:19)
at processTicksAndRejections (internal/process/task_queues.js:95:5)
at async ViteNodeRunner.cachedRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:129:12)
at async request (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:152:16)
at async /Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/nuxt@3.0.0-rc.12/node_modules/nuxt/dist/app/composables/index.mjs:46:31
at async ViteNodeRunner.directRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:250:5)
at async ViteNodeRunner.cachedRequest (/Users/bgd/Documents/Projects/scores-plus/node_modules/.pnpm/vite-node@0.24.5/node_modules/vite-node/dist/client.mjs:129:12)
@manniL
Copy link
Member

manniL commented Nov 2, 2022

Hey! This should be resolved when using edge channel, or in the upcoming RC.

Duplicate of #15231

@manniL manniL closed this as not planned Won't fix, can't repro, duplicate, stale Nov 2, 2022
@danielroe danielroe added the 3.x label Jan 19, 2023
@danielroe danielroe transferred this issue from nuxt/framework Jan 19, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants