Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Solution: Language server crashes due to {'no such file or directory', 'edoc.app'} #431

Closed
Tomboyo opened this issue Dec 6, 2020 · 1 comment · Fixed by #434
Closed

Comments

@Tomboyo
Copy link

Tomboyo commented Dec 6, 2020

I'm opening this issue to document a solution to a fatal startup error in the ElixirLS plugin for VSCode. The root cause has nothing to do with ElixirLS itself, but is rather an issue with the user's installation of Erlang that produces a non-obvious error message (at least, non-obvious for less-experienced elixir users like myself.) Hopefully this is helpful to someone else in the future. Thanks!

The problem

The language server crashes 5 times and gives up when VSCode starts because it encounters a match error while invoking Application.ensure_all_started(:language_server, :temporary) in ElixirLS.LanguageServer.CLI. The match error is: No match of right hand side value: {:error, {:edoc, {'no such file or directory', 'edoc.app'}}}.

The Root Cause

This is because on Fedora 32 (and likely other distros), the base installation of erlang does not ship with the edoc utility; this must be installed separately with dnf install erlang-edoc. Once erlang-edoc is installed, the language server starts like normal.

Environment

  • Elixir & Erlang versions (elixir --version): Erlang/OTP 22 [erts-10.7.2.5] [source] [64-bit] [smp:8:8] [ds:8:8:10] [async-threads:1] [hipe], Elixir 1.11.2
  • Operating system: Fedora 32
  • Editor or IDE name (e.g. Emacs/VSCode): VSCode
  • Editor Plugin/LSP Client name: ElixirLS: Elixir support and debugger, version 0.6.2
@axelson
Copy link
Member

axelson commented Dec 7, 2020

Thanks for the report! There is now an error message that has been added for this case in #434

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants