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

Use of worker-plugin does not work with Next.js 10.0.6+ #1

Open
Manc opened this issue Feb 24, 2021 · 0 comments
Open

Use of worker-plugin does not work with Next.js 10.0.6+ #1

Manc opened this issue Feb 24, 2021 · 0 comments

Comments

@Manc
Copy link
Owner

Manc commented Feb 24, 2021

Whilst building with Next.js up to version 10.0.5 works, using 10.0.6 and 10.0.7 fails like this:

Error: Cannot find module 'webpack/lib/ParserHelpers'
Require stack:
- /[…]/node_modules/worker-plugin/dist/worker-plugin.js
- /[…]/next.config.js
- /[…]/node_modules/next/dist/next-server/server/config.js
- /[…]/node_modules/next/dist/next-server/server/next-server.js
- /[…]/node_modules/next/dist/server/next.js
- /[…]/node_modules/next/dist/server/lib/start-server.js
- /[…]/node_modules/next/dist/cli/next-dev.js
- /[…]/node_modules/next/dist/bin/next
    at Function.Module._resolveFilename (internal/modules/cjs/loader.js:880:15)
    at Function.Module._load (internal/modules/cjs/loader.js:725:27)
    at Module.require (internal/modules/cjs/loader.js:952:19)
    at require (internal/modules/cjs/helpers.js:88:18)
    at Object.<anonymous> (/[…]/node_modules/worker-plugin/dist/worker-plugin.js:27:34)
    at Module._compile (internal/modules/cjs/loader.js:1063:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
    at Module.load (internal/modules/cjs/loader.js:928:32)
    at Function.Module._load (internal/modules/cjs/loader.js:769:14)
    at Module.require (internal/modules/cjs/loader.js:952:19)
    at require (internal/modules/cjs/helpers.js:88:18)
    at Object.<anonymous> (/[…]/next.config.js:1:22)
    at Module._compile (internal/modules/cjs/loader.js:1063:30)
    at Object.Module._extensions..js (internal/modules/cjs/loader.js:1092:10)
    at Module.load (internal/modules/cjs/loader.js:928:32)
    at Function.Module._load (internal/modules/cjs/loader.js:769:14) {
  code: 'MODULE_NOT_FOUND',
  requireStack: [
    '/[…]/node_modules/worker-plugin/dist/worker-plugin.js',
    '/[…]/next.config.js',
    '/[…]/node_modules/next/dist/next-server/server/config.js',
    '/[…]/node_modules/next/dist/next-server/server/next-server.js',
    '/[…]/node_modules/next/dist/server/next.js',
    '/[…]/node_modules/next/dist/server/lib/start-server.js',
    '/[…]/node_modules/next/dist/cli/next-dev.js',
    '/[…]/node_modules/next/dist/bin/next'
  ]
}

I have tried with and without the option future: { webpack5: true } in next.config.js.

See Git branch next-latest (diff).

Related issues of the Next.js repository:

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant