-
-
Notifications
You must be signed in to change notification settings - Fork 9.4k
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 error with new CRA Webpack config #5074
Fix error with new CRA Webpack config #5074
Conversation
Codecov Report
@@ Coverage Diff @@
## next #5074 +/- ##
=======================================
Coverage 35.05% 35.05%
=======================================
Files 593 593
Lines 7348 7348
Branches 1000 1000
=======================================
Hits 2576 2576
Misses 4259 4259
Partials 513 513
Continue to review full report at Codecov.
|
This seems to break our example test, can you confirm this fix? |
My apologies @ndelangen, I've fixed that - I didn't test against the old config filename properly. I've confirmed the new fix locally with the old |
The CLI tests are now passing for this work, the failures are related to something else:
@igor-dv, let me know if you have any suggestions here. |
@mrmckeb Aside from the vue failure, there's also a failure directly related to this change in
As I understand it, your update is intended to solve this problem .. but then I don't understand why that test is failing. Confused... 😕 |
#5077 to many PRs created already |
@shilman From what I can see, this test actually installs Storybook from I can see that the new Then, I can see that
This is the issue that the PR aims to resolve. I've tested locally, but this CI test seems flawed in that it pulls in the published version. As this is now affecting users (as of two days ago), it would be great to get this merged and released ASAP. As a sanity check, you can install create-react-app locally, then simply rename the
I should have tested this more thoroughly with @igor-dv before |
No, it should use a local linked version |
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.
Cool, thanks
Fix error with new CRA Webpack config
Note that this change breaks storybook with In this case, Easy workaround is upgrade |
@simonbuchan, unfortunately we can't just require |
Oh man, that's a tough one, with that as a restriction, you're doing pretty good! For this PR removing the My preference would be to offer some option to override the scripts module used at that point, (e.g. Note that support for following the binstub is already broken on windows, as binstubs are not symlinks on windows, so |
Interesting, I use WSL on Windows, so I've not run into that issue @simonbuchan, but great to know as we'll likely hit it at some point. The reason we removed However, I'm a little confused as to why this PR broke functionality for you - as I would expect |
It's a problem when In that case, the later |
Issue: #5077
What I did
@igor-dv, it looks like the code you had worked fine - except for the
require.resolve
on the first file, which caused the whole script to fall over if the file did not exist. This fix has been tested locally and works.How to test
In
node_modules/react-scripts
, remove the current webpack configs and use the new config fromcreate-react-app
EDIT: As
[email protected]
has been released, this can be tested by installing create-react-app, and running, then downgrading to [email protected], and running again.