Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
We have a yarn workspace with several packages (one per project) and a zero install PNP strategy enabled.
Now we are migrating our CI build to NIX, and one thing that comes in naturally is that you try to sandbox each project's build as much as possible and limit its inputs as much as possible.
This means that for each build job, we copy in the shared files in the workspace root & just the one package directory that is being built.
Now, the problem is, that yarn breaks down with an error
Usage Error: Couldn't find foo in the currently installed PnP map
wherefoo
is declared in the copied-in project dependencies & certainly is installed in the cache.Running
yarn why foo
in the sandbox correctly reports that it is installed and that it's because the package in question declares it as a dependency.Nonetheless, I do get the error any time I try to run anything through yarn that touches that packages (for example
yarn workspaces foreach run xxx
).Is an expected behavior and/or a known bug, that omitting some workspace packages breaks the PnP map checks?
When I run
yarn install
in the sandbox, I get it working (while also obviously getting a ton of changes since now yarn has more packages than is required), but doesn't make much sense to do sincezero install
right...I have “fixed” it for now by copying in the whole
packages/
directory instead of being selective, but that obviously results in extraneous work & likely builds too.Some context info:
Beta Was this translation helpful? Give feedback.
All reactions