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
fix(resolve-dependencies): don't fail when dependency tree doesn't contain parent package #5614
Conversation
…contain parent package
Thanks, we need to add a test for this. I don't want this to regress in the future. |
Yes. I'll try to prepare something for this soon, but couldn't find the exact scenario when this happens, so I need to keep digging a bit. |
@zkochan I've tried to reproduce this scenario in my test cases through In the meantime, I found the issue with our repository. At first, we wanted to use the same package versions as we did before the migration, but I noticed that pnpm sets The list of relevant dependencies (and the respective versions):
Note: The project has fixed dependency versions. The error disappears as soon as I upgrade every dependency to the latest version, but I want to elaborate on the things I found, because this might be a problem somewhere else, not here. For example here What I found in the Maybe there is an obvious reason why this is happening, but I've reached a barrier here. Any help would be appreciated 🙏🏼 |
it will probably only work in the |
Yes, it worked in the root folder, but we wanted to set it on a per-project basis. Also, the per-project configuration is mentioned in the docs, so I thought it will work, but apparently, it didn't. |
I don't understand why you want to set it per project. You can set it in the root and then use |
Because we want our example projects to always be copiable from the monorepo and to let people use them without any modifications. Therefore we can't set the dependencies to Also, this configuration issue is not relevant to the problem I'm trying to solve in this PR. |
The correct fix is in this PR: #5628 |
This PR fixes the problem mentioned in #5327.
We started experiencing problems with
pnpm install
when migrating our dashboard to our monorepo. Although the dashboard project was using yarn originally, I decided to migrate to pnpm in the standalone repository first. Everything was working fine there. It only started breaking when the project was moved to the monorepo.P.S: The problem can be reproduced in our repository by removing pnpm-lock.yaml and running
pnpm install
.