unjs / unplugin

Unified plugin system for Vite, Rollup, Webpack, esbuild, Rolldown, and more
https://unplugin.unjs.io
MIT License
3.09k stars 114 forks source link

ERROR Cannot find package 'webpack-sources' in 1.13.0 #412

Closed oripka closed 2 months ago

oripka commented 2 months ago

Environment

unplugin 1.13.0

Reproduction

pnpm install
Scope: all 5 workspace projects
../oripka prepare$ nuxt prepare
│  ERROR  Cannot find package 'webpack-sources' imported from /Users/otr/code/labguides-refactor/node_modules/.pnpm/unplugin@1.13.0/node_modules/unplugin/dist/index.mjs
│   at packageResolve (node:internal/modules/esm/resolve:842:9)
│   at moduleResolve (node:internal/modules/esm/resolve:915:18)
│   at defaultResolve (node:internal/modules/esm/resolve:1132:11)
│   at ModuleLoader.defaultResolve (node:internal/modules/esm/loader:557:12)
│   at ModuleLoader.resolve (node:internal/modules/esm/loader:526:25)
│   at ModuleLoader.getModuleJob (node:internal/modules/esm/loader:249:38)
│   at ModuleJob._link (node:internal/modules/esm/module_job:126:49)
│  ERROR  Cannot find package 'webpack-sources' imported from /Users/otr/code/labguides-refactor/node_modules/.pnpm/unplugin@1.13.0/node_modules/unplugin/dist/index.mjs

Describe the bug

Updating to unplugin 1.13.0 causes this bug in my Nuxt project. ERROR Cannot find package 'webpack-sources' in 1.13.0.

Overriding to the older version helps

    "pnpm": {
        "overrides": {
        "unplugin": "1.12.4"
        },

Additional context

No response

Logs

No response

vinoddotcom commented 2 months ago

I have encountered the same problem.

antfu commented 2 months ago

Should be fixed in v1.13.1 with 6d4d2b13277e3904419d8b8227c6336930b9a2ad