-
Notifications
You must be signed in to change notification settings - Fork 145
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
Support packageManager
field in package.json and provide the requested version automatically
#871
Comments
Thanks for the report! Yea this is currently a limitations as we only support one version of pnpm right now. I'd be ideal if we supported the |
My suggestion for the time being would be to not use strict engine checks. |
vite-plugin-svelte stopped bumping the engine constraint with renovate, so for that repo it isn't time sensitive right now. However with the upcomping pnpm 8 and it's breaking changes, it would be great if webcontainers detected and supported it to avoid inconsistencies between locally used pnpm@8 and pnpm@7 inside webcontainers. at the very least you would have to bump pnpm@7 to 7.24 or later so that it can understand the new lockfile format v6, otherwise projects that switched to the new format might be incompatible. |
fyi, projects using pnpm8 are going to use lockfile format v6 by default which is not supported by the current pnpm version deployed on stackblitz webcontainers
|
Thanks for putting this on our radar. I have seen the changes in pnpm and we definitely need to update to the latest version so both versions of the lock file are supported and that newer projects don't break. |
If you can't support 8 right away, going up to 7.24 might help to support the new lockfile format at least. |
Yep, I think we may be able to support 8. The problem will still be the exact version from the |
@d3lm what is the progress of pnpm v7.24 / v8 bump? |
@Shinigami92 Thanks for the info. The plan is to update soon-ish and I will let you know once it's on prod. |
Hey all, just wanted to give an update and say that pnpm 8.2.0 is now rolled out to production. We don't support the |
Is your feature request related to a problem? Please describe:
After updating pnpm and the engine restriction in a repository, it may no longer be compatible with webcontainers version of pnpm
see #861
Describe the solution you'd like:
Support the
packageManager
field in package.json similarly to corepack.Describe alternatives you've considered:
Use a more relaxed engine constraint and live with the fact that webcontainers use a different version of pnpm
Additional context:
https://nodejs.org/api/packages.html#packagemanager
https://nodejs.org/api/corepack.html
Running corepack inside webcontainer might not be feasible, but you can do it without by simply parsing packageManager and fetching the version from npm registry as well:
https://github.com/sveltejs/vite-plugin-svelte/blob/74fd16db25d0be6c624e3d7e77b170ff7afb34ed/.github/workflows/ci.yml#L46-L48
request extracted from this comment: #861 (comment)
The text was updated successfully, but these errors were encountered: