-
Notifications
You must be signed in to change notification settings - Fork 171
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
Validation should be configurable based on operation #406
Comments
Currently you can use an env variable to disable validation, but I think you’re asking about something else. Do you have a specific format for the configuration in mind? |
Fwiw as a package manager author that's exactly why I'd prefer Corepack to not support this. Mixing package managers together has been a relatively frequent source of issues, going from crashes (since the loader hooks aren't setup) to subtly incorrect behaviour (since the Yarn configuration and internal hooks are skipped). If this feature was supported, we'd likely strongly advise our users against it - perhaps even making it a warning or error if we detected this pattern. |
Most packages managers don't install loader hooks. Like npm for install and Bun for run should work perfectly well together I'd think. Maybe Yarn would advise against it and that's fine, but I don't think that's universal. Most people seem to version pin to avoid corrupting lockfiles. That only matters for adding or removing dependencies. If those are the only operations those users need version pinning for, it would open up other use cases to allow validation to be enforced only for those operations. |
So you might say one of Corepack's goals is to ensure package managers do not work together? |
It should be possible to define package manager constraints separately for certain operations, for example
install
/uninstall
operations could get validation butrun
would allow any package manager. This would allow mixing and matching of package managers, for examplepnpm
to install packages but then Bun to run scripts.Split off from #402.
The text was updated successfully, but these errors were encountered: