Skip to content
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

Build crashing with OOM #533

Open
Makisuo opened this issue May 3, 2024 · 3 comments
Open

Build crashing with OOM #533

Makisuo opened this issue May 3, 2024 · 3 comments

Comments

@Makisuo
Copy link

Makisuo commented May 3, 2024

I have a package with a lot of entries and it seems to consume overly much Memory, aswell as crashing with Out of Memory since reaching some threshold of entry files.

Any way for me to limit bunchees concurrent building or setting Memory Limits for my builds to not crash from it?

@pixelshades/styles:build: <--- JS stacktrace --->
@pixelshades/styles:build: 
@pixelshades/styles:build: FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory
@pixelshades/styles:build: ----- Native stack trace -----
@pixelshades/styles:build: 
@pixelshades/styles:build:  1: 0x100da959c node::Abort() [/Users/A200286255/Library/Application Support/fnm/node-versions/v20.11.1/installation/bin/node]

Here is also the package responsible for it:

https://github.com/telekom/pixelshades/blob/main/packages/styles/package.json

@huozhi
Copy link
Owner

huozhi commented May 5, 2024

@Makisuo I'm not seeing this problem with bunchee@5.1.5 which is used on main branch now, are you still seeing the issue?

@Makisuo
Copy link
Author

Makisuo commented May 7, 2024

Kinda fixed it by setting NODE_OPTIONS=--max-old-space-size=8192, but memory is spiking still super high at around ~5gb compared to the ~600mb for the other packages.

@huozhi
Copy link
Owner

huozhi commented May 7, 2024

I tested with removing that flag and it still works for me

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants