-
-
Notifications
You must be signed in to change notification settings - Fork 2.2k
only run postinstall if package.json exists #6998
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
Conversation
🦋 Changeset detectedLatest commit: 12befed The changes in this PR will be included in the next version bump. This PR includes changesets to release 1 package
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
Should we have another bigger try-catch here in case there are other weird unexpected errors? Given what we're using the postinstall script for here, it doesn't seem to me there would ever be a situation where I would prefer the whole install to fail. |
|
In general I'm not a fan of all-encompassing try-catch blocks, because they prevent us from catching actual logic bugs. Like, the thing in #6987 (comment) with |
Co-authored-by: Simon H <[email protected]>
|
Logging the exception sounds fine. I'm just saying that we shouldn't fail the whole install, because that doesn't help anyone, especially for something that would be generated when they build the project anyway. |
package.jsonis missing (for instance on apnpm fetch) #6987Please don't delete this checklist! Before submitting the PR, please make sure you do the following:
Tests
pnpm testand lint the project withpnpm lintandpnpm checkChangesets
pnpm changesetand following the prompts. All changesets should bepatchuntil SvelteKit 1.0