stimulus-lsp icon indicating copy to clipboard operation
stimulus-lsp copied to clipboard

Add support for Sublime Text

Open marcoroth opened this issue 1 year ago • 2 comments

https://lsp.sublimetext.io/language_servers/

marcoroth avatar May 10 '24 18:05 marcoroth

Hi, I made a PR to add stimulus-lsp to Sublime LSP docs (https://github.com/sublimelsp/LSP/pull/2391). At the time it was working ok, but currently I am getting an error:

  • Sublime Text 4192
  • stimulus-language-server v1.0.4
  • sublime-lsp v2.3.0
  • node v22.12.0
stimulus: <--- Last few GCs --->
stimulus: 
stimulus: [8327:0x138008000]    20472 ms: Mark-Compact 2004.9 (2086.2) -> 1993.9 (2091.0) MB, pooled: 0 MB, 781.83 / 0.00 ms  (average mu = 0.395, current mu = 0.409) allocation failure; scavenge might not succeed
stimulus: [8327:0x138008000]    22508 ms: Mark-Compact 2007.5 (2095.9) -> 2000.7 (2097.7) MB, pooled: 0 MB, 1739.96 / 0.00 ms  (average mu = 0.243, current mu = 0.146) allocation failure; GC in old space requested
stimulus: 
stimulus: 
stimulus: <--- JS stacktrace --->
stimulus: 
stimulus: FATAL ERROR: Reached heap limit Allocation failed - JavaScript heap out of memory
stimulus: ----- Native stack trace -----
stimulus: 
stimulus:  1: 0x100473798 node::OOMErrorHandler(char const*, v8::OOMDetails const&) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  2: 0x10069bd48 v8::internal::V8::FatalProcessOutOfMemory(v8::internal::Isolate*, char const*, v8::OOMDetails const&) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  3: 0x100885fe8 v8::internal::Heap::stack() [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  4: 0x1008843f4 v8::internal::Heap::CollectGarbage(v8::internal::AllocationSpace, v8::internal::GarbageCollectionReason, v8::GCCallbackFlags) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  5: 0x100879130 v8::internal::HeapAllocator::AllocateRawWithLightRetrySlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  6: 0x10087996c v8::internal::HeapAllocator::AllocateRawWithRetryOrFailSlowPath(int, v8::internal::AllocationType, v8::internal::AllocationOrigin, v8::internal::AllocationAlignment) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  7: 0x10085c3e8 v8::internal::Factory::NewFillerObject(int, v8::internal::AllocationAlignment, v8::internal::AllocationType, v8::internal::AllocationOrigin) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  8: 0x100c5f878 v8::internal::Runtime_AllocateInOldGeneration(int, unsigned long*, v8::internal::Isolate*) [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]
stimulus:  9: 0x1010e1af4 Builtins_CEntry_Return1_ArgvOnStack_NoBuiltinExit [/Users/oscar/.nvm/versions/node/v22.12.0/bin/node]

Any idea how to solve it?

ocarreterom avatar Jan 30 '25 08:01 ocarreterom

Hey @ocarreterom, thanks for reporting!

I think this is a problem of the codebase size, not necessarily with Sublime. I've been reworking some of the internals to use less memory that should make it much more efficient (or actually usable) on some larger codebases with a bunch of JavaScript files and dependencies.

But I think the issue you are seeing is #283 .

marcoroth avatar Feb 02 '25 07:02 marcoroth