-
Notifications
You must be signed in to change notification settings - Fork 66
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(parcel): more robust handling of missing package.json #882
Conversation
Codecov Report
@@ Coverage Diff @@
## master #882 +/- ##
==========================================
+ Coverage 91.76% 91.77% +<.01%
==========================================
Files 43 43
Lines 1786 1787 +1
==========================================
+ Hits 1639 1640 +1
Misses 147 147
Continue to review full report at Codecov.
|
It does fix it but it's not setting I was just submitting my own fix, #883, I'll let you select the right one! |
I just noticed. Both a missing |
I think you need
or something like that in the current fix, as pkg itself might be null. It's still failing for me with that fix. My fix at https://github.com/adobe/helix-cli/pull/883/files works (but maybe it's not the preferred style) |
const pkg = await super.getPackage() || {}; | ||
const pack = pkg.devDependencies ? pkg : Object.assign(pkg, { | ||
devDependencies: { | ||
hyperapp: '*', |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
this is set twice now...
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Only when devDependencies
didn't exist before.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
why do you need it, btw ?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
In order to get parcel
to think that the pragma for JSX files is h
instead of React.createElement
without forcing people to add it to their JSX files.
🎉 This PR is included in version 2.5.3 🎉 The release is available on: Your semantic-release bot 📦🚀 |
I do not see a newly added test that would prevent for this bug to happen again... |
fixes #881
@bdelacretaz does this fix your issue?