-
Notifications
You must be signed in to change notification settings - Fork 73
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
Large Monorepo OOM Errors with Turbosnap Enabled #1029
Comments
hello @ChrisSargent have you tried the workarounds described here: Why is my build failing with an Out of memory error? |
Hi @cgbl-90 - yes, we have 4gb of max old space size set in FYI, we've also trying setting the max old space size much higher but it eventually dies. |
@ChrisSargent thanks for reporting this! It appears to be coming from our lock file parsing lib and improving that is going to take quite a bit of effort (which we're discussing internally). For now though, I merged in #1140 which should help with preventing the OOM errors at the cost of running a full Chromatic build when dependencies change and the lock file is too large to parse. Feel free to give If you continue to see issues, try setting the environment variable |
@codykaup - thanks for the response we can give it a try and report back. For reference our lock file is only 2.2MB. To work around in the last few months, we've just been skipping turbosnap if - name: 'Setup: Check yarn.lock changes'
run: |-
UNCHANGED_YARN_LOCK=$(./scripts/cicd/checkfile-unchanged.sh yarn.lock)
echo "UNCHANGED_YARN_LOCK=$UNCHANGED_YARN_LOCK" >> $GITHUB_ENV
- name: 'Build & Deploy: Storybook'
run: chromatic --only-changed=$UNCHANGED_YARN_LOCK
env:
CHROMATIC_PROJECT_TOKEN: ${{ secrets.CHROMATIC_PROJECT_TOKEN }} #!/bin/bash
# Check if a specified file has changed since the last commit
FILE_TO_CHECK=$1
if git diff --name-only HEAD^ HEAD | grep -q "$FILE_TO_CHECK"; then
# File is not unchanged
echo "false"
else
# File is unchanged
echo "true"
fi |
Well that's a bummer, we might have to lower our original value then. 😞 You (or anybody else that might come across this) should be able to set |
Bug report
We are seeing OOM errors during the Chromatic build process if we have Turbosnap enabled. In particular this seems to happen if there's any
package.json
change causing a change to theyarn.lock
file.We have tried setting
max-old-space
pretty high but it still happens.Critical Logs are below, nothing interesting in the stacktrace.
This started happening after this upgrade (and we also started getting errors about the
traceChanged
option seemingly changed fromexpand
toexpanded
.The text was updated successfully, but these errors were encountered: