next-runtime
next-runtime copied to clipboard
Site Deploy Fails Using Yarn 2 PnP
Describe the bug
I recently activated Yarn PnP on my site. However, this is causing the validateNextUsage
to fail. Switching back to the traditional node_modules
fixes the issue.
To Reproduce
- Create a site using Yarn 2 PnP
- Install Next and deploy to Netlify
Expected behavior Site deploys properly.
Versions
- Next.js: 10.0.9
- plugin (if installed at fixed version): 3.0.3
Any updates on this?
I had the same issue. I "fixed" it too by setting nodeLinker
to "node-modules"
in yarnrc.yml.
But then no pnp support.
Just adding "berry" as a keyword here. Should be addressed asap.
I've been doing some research on this but haven't had much luck on finding a solution. I did find this issue on Yarn 2's repo that seems to be what we're running into here: https://github.com/yarnpkg/berry/issues/1467
Is there a way for me to locally test this sort of thing? It's a pretty specific issue and I'm not really sure how to get started with it, and I don't see any tests that relate to validateNextUsage
.
Is Yarn v2 or v3 used here?
This is something we may address in the future, but for now see https://docs.netlify.com/configure-builds/manage-dependencies/#yarn where it shows you how to configure yarn to set a yarnpath in conjunction with nodelinker.
cc: @kitop