Description
On Windows 11 / WSL2 i got many crashes of Volar and error is about JavaScript heap out of memory
Please, not that I'm using vscode insiders but the rest of my team have the same problem and are on vscode classic.
I downgraded my typescript version from 5.2.2
to 5.1.3
since i have seen in the Volar changelog that it was supported a few versions ago.
When I haven't the error, the save code action is really long, and typing is not always refreshed in Vue files.
I installed Vue Langage Features (Volar) v1.8.11
(the problem is also present with 1.8.1
or 1.8.10
for example) and using it in take overmode, vue-tsc 1.8.11
.
I'm working on a monorepo with multiple apps and packages.
Please, see the full error bellow (i activated trace server: messages):
[Trace - 2:24:08 PM] Sending request 'textDocument/inlayHint - (711)'.
[Trace - 2:24:08 PM] Sending notification '$/cancelRequest'.
[Trace - 2:24:08 PM] Sending request 'textDocument/inlayHint - (712)'.
[Trace - 2:24:08 PM] Sending request 'textDocument/semanticTokens/range - (713)'.
[Trace - 2:24:09 PM] Sending request 'textDocument/hover - (714)'.
[Trace - 2:24:09 PM] Sending notification '$/cancelRequest'.
<--- Last few GCs --->
[193463:0x69f3dd0] 447569 ms: Scavenge 2027.2 (2079.5) -> 2023.2 (2081.3) MB, 7.2 / 0.0 ms (average mu = 0.884, current mu = 0.527) allocation failure;
[193463:0x69f3dd0] 447586 ms: Scavenge 2028.8 (2081.3) -> 2023.2 (2083.0) MB, 7.2 / 0.0 ms (average mu = 0.884, current mu = 0.527) allocation failure;
[193463:0x69f3dd0] 447607 ms: Scavenge 2030.8 (2083.0) -> 2023.8 (2099.0) MB, 7.8 / 0.0 ms (average mu = 0.884, current mu = 0.527) allocation failure;
<--- JS stacktrace --->
FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory
1: 0xb7d990 node::Abort() [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
2: 0xa88a17 [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
3: 0xd76390 v8::Utils::ReportOOMFailure(v8::internal::Isolate*, char const*, bool) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
4: 0xd76737 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, bool) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
5: 0xf540d5 [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
6: 0xf6654d v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
7: 0xf40c9e v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
8: 0xf42057 v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
9: 0xf234ba v8::internal::Factory::NewFillerObject(int, v8::internal::AllocationAlignment, v8::internal::AllocationType, v8::internal::AllocationOrigin) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
10: 0x12ea97f v8::internal::Runtime_AllocateInYoungGeneration(int, unsigned long*, v8::internal::Isolate*) [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
11: 0x1727339 [/home/etienne/.vscode-server-insiders/bin/f36df69328ed10f76d4be03e8a82b61794b49711/node]
[Info - 2:24:09 PM] Connection to server got closed. Server will restart.
true
I hope anyone can help us! 🙏 It's really hard to work with Volar in this state.