VS Code Extension woes


Hi all, I’ve been editing my Julia code in vim happily but I wanted to try out VS Code with the plugin to see how I liked it. However, while syntax highlighting and autoindentation works fine, the extension seems to be stuck loading the language server (for linting, I guess?); the bottom left always reads “Julia: starting up”. It’s taking up 100% of one CPU and continuously taking up more memory, until it crashes (every 5 minutes or so). The debug tools in Code show that it’s exhausting the JS heap.

Has anyone else seen these problems, and if so how did you fix it? I’m running the latest released versions of both Julia and Code.


This might be related to https://github.com/JuliaEditorSupport/julia-vscode/issues/255 (there’s a possible fix at the bottom of that issue discussion)


The main symptom of that issue is a “Julia: busy” message, not “Julia: starting up” though. It might be worth opening a new issue.


I switched over the VS code from Atom and experience the same issues with busy all the time. That being said it seems to be more responsive than Atom. and do not contemplate going back.


Do you think you could follow the instructions here to turn on logging and open an issue with the debugging output?


I’ll do this now. I don’t think from the symptoms that it’s due to the issue that @rdeits linked above. Also, I just tested on my Windows laptop instead of my Linux workstation and everything worked fine; I don’t know how significant that is but I’ll mention it in the issue.


@ZacLN I tried to follow the instructions (edited “main.jl” in the language server subdirectory to call with debug mode = true), but I don’t see any output in Code. I think your instructions must have been written for an older version, the only drop down menu options I have for output are ‘Search’, ‘Tasks’, ‘Extensions’, and ‘Git’. Is there an easy way to have the language server write debug output to a file instead, perhaps?


Hmm thats very strange there really ought to be some output there even without debug mode enabled. Did you restart vscode?

A more basic test could be to cd to LanguageServer from julia (in julia-vscodeinstalldir/scripts/languageserver/packages/LanguageServer) manually include the package (include("src/LanguageServer.jl")) and try running the tests (include("test/runtests.jl"))


This is my line 26 - I am on Windows 10

server = LanguageServerInstance(STDIN, conn, ls_debug_mode, Base.ARGS[1])

How do I set it to True?


@ArchieCall Just change ls_debug_mode to true… I left a comment to remind myself what the original was.


@ZacLN Ok, I did find an error running the tests as described; the error line reads

INFO: ERROR: (unhandled task failure): KeyError: key "Content-Length" not found

That’s the only error.

Edit: Ran the same check on my Windows laptop, get the same error, but the language server does start up successfully, so it’s not causing the behavior I’m observing.


I got the true line enabled. Just by virtue of doing this the Julia: busy indicator is now almost always showing as Julia: ready. Much better.

There is plenty of debug output now showing in the Output panel.

The intellisense/tips stuff seems to work only intermittently. Maybe better than before, but not much.

Do you want me to paste this output somewhere?