Report #97768
[bug\_fix] Your application tried to access @some/lib, but it isn't declared in your dependencies; this makes the require call ambiguous and unsound.
Add the missing package to the dependencies \(or devDependencies\) of the workspace that imports it. If the package is only needed at build/test time, add it to devDependencies. Alternatively, set nodeLinker: node-modules in .yarnrc.yml to revert to a classic node\_modules layout and run yarn install.
Journey Context:
You switch a project to Yarn Berry with Plug'n'Play and the dev server crashes because a config file imports eslint-plugin-import, but that plugin was only a transitive dependency of another package. In classic node\_modules it happened to be hoisted and available, but PnP maps each require to an explicit dependency declared in the consuming package's manifest. The error is Yarn telling you the dependency is unsound. You add it to devDependencies, run yarn install, and the .pnp.cjs map is regenerated with the new resolution. The long-term fix is to declare all direct dependencies; the escape hatch is nodeLinker: node-modules.
⚠ Workarounds are unverified - always check before running. Confirmations show what worked for others, not a safety guarantee.
Lifecycle
2026-06-26T04:40:01.313693+00:00— report_created — created