JavaScript heap out of memory when running pnpm run check
Thavarajan opened this issue · 3 comments
> botpress@ lint:check /home/thavarajan.m/projects/test/node-apps/botpress
> eslint ./ --ext .ts --ext .tsx
<--- Last few GCs --->
[334098:0x5d89d10] 30703 ms: Mark-Compact (reduce) 2047.8 (2084.4) -> 2046.3 (2082.1) MB, 418.76 / 0.00 ms (+ 97.8 ms in 28 steps since start of marking, biggest step 5.4 ms, walltime since start of marking 532 ms) (average mu = 0.304, current mu = 0.[334098:0x5d89d10] 31341 ms: Mark-Compact (reduce) 2047.5 (2082.1) -> 2046.3 (2082.1) MB, 458.45 / 0.00 ms (+ 38.5 ms in 15 steps since start of marking, biggest step 5.6 ms, walltime since start of marking 510 ms) (average mu = 0.265, current mu = 0.
<--- JS stacktrace --->
FATAL ERROR: Ineffective mark-compacts near heap limit Allocation failed - JavaScript heap out of memory
1: 0xc9e850 node::Abort() [node]
2: 0xb720ff [node]
3: 0xec1a70 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
4: 0xec1d57 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [node]
5: 0x10d3dc5 [node]
6: 0x10d4354 v8::internal::Heap::RecomputeLimits(v8::internal::GarbageCollector) [node]
7: 0x10eb244 v8::internal::Heap::PerformGarbageCollection(v8::internal::GarbageCollector, v8::internal::GarbageCollectionReason, char const*) [node]
8: 0x10eba5c v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [node]
9: 0x10c1d61 v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [node]
10: 0x10c2ef5 v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [node]
11: 0x10a0466 v8::internal::Factory::NewFillerObject(int, v8::internal::AllocationAlignment, v8::internal::AllocationType, v8::internal::AllocationOrigin) [node]
12: 0x14fb386 v8::internal::Runtime_AllocateInYoungGeneration(int, unsigned long*, v8::internal::Isolate*) [node]
13: 0x7f632e699ef6
Aborted (core dumped)
got this error when i try to run pnpm run check
, just follow the instruction from the index page, am i missing anything
i used nvm to maintain node multiple versions, was it a reason?
I just ran it without problem locally. Have you tried increasing the heap for this process ?
You can try something like: export NODE_OPTIONS=--max_old_space_size=4096
or 8192
If it still does not work, don't worry; This command only lints your code before you open a pull request to the repo. In any case, the linting will run in a github action to check if you are allowed to merge.
On another note, why did you clone this repo ? Do you intend to contribute ? If so, what feature/ bug fix do you plan on working on ?
Thanks for the input, it works, No i am new to this realm, just out of curiosity try this,
I try to clone and launch a botpress server and try to know the internals how it behaves
Good, no problem.
Just be carefull not to confuse Botpress v12 (the previous on premise botpress server), with the new and current cloud product https://app.botpress.cloud/
Frank