doo

doo

ElixirLS in vscode: Failed to run 'elixir'

My problem

Env

OS: Window

# installed by asdf
elixir 1.15.2-otp-26
erlang 26.2.0

ElixirLS
0.20.0 (LTS)

When I run vscode and open the elixir file, a pop-up message like the below

Failed to run 'elixir' command. ElixirLS will probably fail to launch. Logged PATH to Development Console.

So, I checked view - output - elixirLS

[Error - 6:46:56 PM] Server process exited with code 1.
C:\Users\doo\.asdf\shims\erl.exe�� ������ ���� ���� Windows ������ ȣȯ���� �ʽ��ϴ�. ��ǻ���� �ý��� ������ Ȯ���ϰ� ����Ʈ���� �Խ��ڿ��� �����Ͻʽÿ�.
[Error - 6:46:56 PM] Server initialization failed.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 6:46:56 PM] The ElixirLS - server crashed 5 times in the last 3 minutes. The server will not be restarted. See the output for more information.
[Error - 6:46:56 PM] ElixirLS - client: couldn't create connection to server.
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 6:46:56 PM] Restarting server failed
  Message: Pending response rejected since connection got disposed
  Code: -32097 
[Error - 6:46:56 PM] Server process exited with code 1.

Nothing works except for the highlighting syntax

I tried to add PATH

echo $PATH

/c/Program Files/Elixir/bin:
/c/Program Files/Erlang OTP/bin:
/c/Users/doo/.asdf/shims:
/c/Users/doo/.asdf/bin

I’m using git bash in vscode *opened by git bash

Expected

intelliSense
Go to definition (custom function, built-in function

Please help me

Marked As Solved

doo

doo

I resolved

on Window
There is no .bat or .exe in .asdf/bin path

# .bashrc
export PATH=$PATH:$PATH:$HOME/.asdf/shims
export PATH=$PATH:$HOME/.asdf/bin

and I modified path
PATH=new_path:$PATH new path priority^
PATH=$PATH:new_path priority v

solution:

# .bashrc
export PATH=$HOME/.asdf/installs/elixir/1.15.2-otp-26/bin:$PATH
export PATH=$HOME/.asdf/installs/erlang/26.2.0/bin:$PATH

Also Liked

cmo

cmo

Can you run elixir? I didn’t think asdf worked on Windows.

Where Next?

Popular in Questions Top

Harrisonl
We have an ECS cluster with 4 services, where each task joins a single cluster, via discovery ECS discovery service. Currently when I de...
New
dokuzbir
Hello, I am trying to convert my lists to string without losing brackets.For start i have 3 map. They look like these buyer = %{ id: ...
New
myronmarston
The Elixir Typespec docs show the following syntax for keyword lists in typespecs: # ... | [key: type] # keyword lis...
New
makeitrein
Hey all, just started picking up Elixir last week and am writing a scraper as a learning project. Baby step #1 is extracting the number ...
New
aadeshere1
I have a another noob question about loop. Since elixir is immutable, while loop is not directly possible. total = 10 while total != 0 ...
New
alice
Hey, Just curious what are the main benefits of Elixir compared to Clojure? When is Elixir more useful than Clojure and vice versa? Th...
New
baxterw3b
Hi guys, i’m new in the Elixir world, and i have to say, that i love it! i’m having some problem to understand anonymous functions with ...
New
chewm
Hi guys, nice to meet you to the whole forum, I’m new here, I’m trying to configure visual studio code for elixir, right now the intellis...
New
jc00ke
Expanding on this topic: https://forum.elixirforum.net/t/map-typespec-question/19217 Let’s say I have a map with required and optional k...
New
jay1
Why is it that the mnesia database isn’t the most preferred database for use in Elixir/Phoenix?
New

Other popular topics Top

yurko
Here are few pieces of (common) Linux knowledge that we use for reasonably small one server apps. We use Ubuntu but this should work for ...
New
Tee
can someone please explain to me how Enum.reduce works with maps
New
chrismccord
This release brings a number of exciting features, including integration with the new Phoenix LiveDashboard and Phoenix LiveView. There h...
New
script
If I have a string “1000 cfu/ml” . I want to remove the characters and / and space . So the string is like this "1000" What is the ...
New
vac
Hi, I'm quite new in Elixir and I'm trying to format a string to a PEM format. I have the certificate value like MIIDBTCCAe2...... and ...
New
freewebwithme
Using vs code and installed ElixirLS: support and debugger. And I got an error popped up on start up says Failed to run ‘elixir’ comma...
New
chensan
I have a User schema with a :from_id field set to type :string: defmodule TweetBot.Repo.Migrations.CreateUsers do use Ecto.Migration ...
New
msaraiva
Surface is an experimental library built on top of Phoenix LiveView and its new LiveComponent API that aims to provide a more declarative...
564 42633 214
New
ovidiubadita
Hey all, I discovered Elixir and I love it. I always wanted to learn a functional programming and I intended to go for Haskell, but afte...
New
baxterw3b
Hi guys, i’m new in the Elixir world, and i have to say, that i love it! i’m having some problem to understand anonymous functions with ...
New

We're in Beta

About us Mission Statement