Skip to content

fix(webpack): increase typescript memory limit #18

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

Merged
merged 1 commit into from
Jul 16, 2025

Conversation

HumbertoL
Copy link
Collaborator

@HumbertoL HumbertoL commented Jul 16, 2025

https://trello.com/c/iu73Ym6U

Issue

I'm still seeing crashing when running the web app locally. Looking closely at the error message, they suggest updating the memory limit on ForkTsCheckerWebpackPlugin

Screenshot 2025-07-16 at 11 06 13 AM

Solution

Looking at the docs for ForkTsCheckerWebpackPlugin, we see that the default limit is 2GB. Let's bump it to 4GB

Screenshot 2025-07-16 at 11 20 25 AM

Testing

I was able to consistently reproduce the crash in cea-desktop with these steps:

  • Checkout main and run yarn start
  • Checkout an old version git checkout 1.504.0
  • Wait several seconds and observe the crash

We can verify that this fix works by:

  • In cea-desktop client, open node_modules/tea-react-scripts/config/webpack.config.js
  • Apply this change to that file (add the line from this PR)
  • Repeat the above test of checking out main and switching to an old branch
  • Verify that the crash no longer occurs

Note that you should still expect to see unrelated compilation errors due to the significant difference between the two versions of the code base. However, the crash should not occur.

@HumbertoL HumbertoL merged commit 79b3ff4 into master Jul 16, 2025
1 check failed
@m2mathew m2mathew deleted the fix/ts-memory-limit branch July 16, 2025 16:41
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

Successfully merging this pull request may close these issues.

2 participants