Skip to content
This repository was archived by the owner on Aug 15, 2025. It is now read-only.
This repository was archived by the owner on Aug 15, 2025. It is now read-only.

Connection to server got closed. Server will not be restarted #1592

Description

@alexcme

Describe the bug
Erlang LS terminited while using vscode on macOS 15.5 (24F74)
Model Name: MacBook Pro
Model Identifier: Mac15,8
Model Number: ZXXXXXXXXXX/A
Chip: Apple M3 Max
Total Number of Cores: 16 (12 performance and 4 efficiency)
Memory: 128 GB

vscode Version: 1.101.1 (Universal)
Commit: 18e3a1ec544e6907be1e944a94c496e302073435
Date: 2025-06-18T13:35:12.605Z
Electron: 35.5.1
ElectronBuildId: 11727614
Chromium: 134.0.6998.205
Node.js: 22.15.1
V8: 13.4.114.21-electron.0
OS: Darwin arm64 24.5.0

erlang-ls.erlang-ls
Version 0.0.46
Last Updated 2025-06-22, 08:13:15

To Reproduce
Have simple code to test that is failing at the time I open vscode in folder with main.erl file:

-module(main).
-export([start/0]).

start() ->
io:fwrite("Hello, world from erlang!~n").

Expected behavior
Expected to see "Hello .." in debug vscode window, but it never ever start

Actual behavior
Immediately after opening folder, even before trying to start it, I see 5 exceptions in OUTPUT window and as such there no way to start anything.
...
Info - 8:17:22 AM] Connection to server got closed. Server will restart.
escript: exception exit: terminating
in function application_controller:call/2 (application_controller.erl:515)
in call from application:'-ensure_all_started/3-lc$^0/1-0-'/1 (application.erl:368)
in call from application:ensure_all_started/3 (application.erl:368)
in call from erlang_ls:main/1 (/home/runner/work/vscode/vscode/erlang_ls/apps/els_lsp/src/erlang_ls.erl:29)
in call from escript:run/2 (escript.erl:906)
in call from escript:start/1 (escript.erl:420)
in call from init:start_it/1
in call from init:start_em/1
[Error - 8:17:22 AM] Connection to server got closed. Server will not be restarted.

Below is output from macOS terminal that works and I would expect be helpful:

xxx@yyy main % which erl
/opt/homebrew/bin/erl
xxx@yyy main % which rebar3
/opt/homebrew/bin/rebar3
xxx@yyy main % erl -compile main
xxx@yyy main % erl -run main start -run erlang halt
Erlang/OTP 28 [erts-16.0.1] [source] [64-bit] [smp:16:16] [ds:16:16:10] [async-threads:1] [jit] [dtrace]

Hello, world from erlang!
xxx@yyy main %

Context

  • erlang_ls version (tag/sha): see above
  • Editor used: vscode (see above)
  • LSP client used:based on vscode version

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions