-
Notifications
You must be signed in to change notification settings - Fork 11.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
Coverage and test runs often result in JavaScript heap out of memory
#5363
Comments
JavaScript heap out of memory
JavaScript heap out of memory
The
On my machine, I have it set in I honestly think this is a very frequent error that is very well documented online. Should we make that default for everyone ? If we do so, could that cause issues on machine that have smaller ram ? |
For the record, if I type "JavaScript heap out of memory" in google, the first link I get is this, which contains all the information to solve that. |
I think we should set it by default--I'm not sure if it would cause issues on machines with too little memory... but the run would fail regardless for them. |
How would you set it ? Shipping a |
We could prepend the npm scripts in
|
On MacOS, vanilla runs of the test and coverage npm scripts often results in a
JavaScript heap out of memory
error. This is a known issue with hardhat NomicFoundation/hardhat#3471.Increasing the allowed old memory to using the following env var fixes the issue
NODE_OPTIONS="--max-old-space-size=8192"
. We should consider documenting this or even setting the env var by default.The text was updated successfully, but these errors were encountered: