Skip to content

Commit 8025bdb

Browse files
committed
update readme
1 parent 6699712 commit 8025bdb

File tree

1 file changed

+24
-2
lines changed

1 file changed

+24
-2
lines changed

README.md

Lines changed: 24 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -343,8 +343,8 @@ Below is a list of configuration options supported by ElixirLS Debugger. Configu
343343
Basic troubleshooting steps:
344344

345345
- Make sure you have hex and git installed
346-
- Make sure github.com and hex.pm are accessible. You may need to configure proxy
347-
- If the extension fails to start ElixirLS you can try cleaning the `Mix.install` directory (location on your system can be obtained by calling `Mix.Utils.mix_cache()` from `iex` session)
346+
- Make sure github.com and hex.pm are accessible. You may need to configure HTTPS proxy. If your setup uses TLS man-in-the-middle inspection you may need to set `HEX_UNSAFE_HTTPS=1`.
347+
- If ElixirLS fails to start you can try cleaning the `Mix.install` directory (location on your system can be obtained by calling `Path.join(Mix.Utils.mix_cache(), "installs")` from `iex` session)
348348
- Restart ElixirLS with a custom command `restart`
349349
- Run `mix clean` or `mix clean --deps` in ElixirLS with custom command `mixClean`
350350
- Restart your editor (which will restart ElixirLS)
@@ -364,6 +364,28 @@ and you installed Elixir and Erlang from the Erlang Solutions repository, you ma
364364

365365
On fedora if you only install the elixir package you will not have a full erlang installation, this can be fixed by running `sudo dnf install erlang` (reported in [#231](https://github.com/elixir-lsp/elixir-ls/issues/231))
366366

367+
If you are seeing the message "Invalid beam file or no abstract code", you need to make sure that your Mix project is set to use the `elixirc` compiler option `--debug-info`, which can be done by adding the following line to your `mix.exs` `project` section:
368+
369+
```
370+
elixirc_options: [debug_info: Mix.env() == :dev]
371+
```
372+
373+
For example:
374+
375+
```
376+
defmodule MyApp.MixProject do
377+
use Mix.Project
378+
379+
def project do
380+
[
381+
app: :my_app,
382+
version: "0.1.0",
383+
elixir: "~> 1.11",
384+
elixirc_paths: elixirc_paths(Mix.env()),
385+
elixirc_options: [debug_info: Mix.env() == :dev],
386+
...
387+
```
388+
367389
If you are using Emacs with lsp-mode there's a possibility that you have set the
368390
wrong directory as the project root (especially if that directory does not have
369391
a `mix.exs` file). To fix that you should remove the project and re-initialize:

0 commit comments

Comments
 (0)