-
-
Notifications
You must be signed in to change notification settings - Fork 26.9k
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
Heap out of memory error while building after updating to 3.3.0 #8130
Labels
Comments
jdtriska
changed the title
Heap out of memory error after updating to 3.3.0
Heap out of memory error while building after updating to 3.3.0
Dec 9, 2019
Also discussed in #8096 |
Thanks--don't know how I missed that! This may indeed be a duplicate of that issue. |
bbfsdev
added a commit
to Bnei-Baruch/kmedia-mdb
that referenced
this issue
Dec 10, 2019
4 tasks
This issue has been automatically marked as stale because it has not had any recent activity. It will be closed in 5 days if no further activity occurs. |
Closing as dupe of #8096. |
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Describe the bug
Hi all,
When updating our project from
react-scripts
3.2.0
to3.3.0
, I encountered this error:We're building this in a container based on
node:10.14.1-alpine
pretty much out of the box with yarn, runningyarn build
, which runs the default CRA commandreact-scripts build
.I have confirmed that switching only the
react-scripts
version between3.2.0
and3.3.0
solves and causes the issue respectively.Our
package.json
is fairly simple for this application, and I've reproduced a somewhat anonymized copy below:Based on a suggestion from an older issue (#4436) I attempted to solve this by instead running:
This did fix the issue, but I would rather not have to manually configure this for all our commands if it's not necessary (I've also noticed this intermittently happens while the webpack server is running via
react-scripts start
). Is there a change that was made in3.3.0
that could have caused this? I've never seen this before, and this update was made in isolation so our code hasn't gotten larger/more complex. I do have a workaround, like I said, but I would definitely appreciate some insight on this to make sure something worse isn't happening deeper inside.Thank you!
EDIT: Also confirmed working with
react-scripts --max_old_space_size=8192 build
. Again, have a workaround, but would be nice to know why it's using so much more memory now.Did you try recovering your dependencies?
Yes, I tried clearing the existing
node_modules
folder andyarn.lock
.Which terms did you search for in User Guide?
I looked for any term related to memory/heap issues, and I couldn't find anything. I did find references to this error here: #4436. I also found references to the error, with a similar solution to the one posted in that issue (--max-old-space-size) in other projects.
Steps to reproduce
react-scripts
version3.2.0
3.3.0
yarn build
Expected behavior
Optimized production build should be produced.
Actual behavior
As mentioned above, the following error is thrown:
Reproducible demo
As mentioned above, I'm working on reproducing this in isolation outside of our app, but that will take a bit (also, it may just have to do with our code size/dependency graph, in which case it won't be reproducible in a basic starter app).
The text was updated successfully, but these errors were encountered: