elixir icon indicating copy to clipboard operation
elixir copied to clipboard

Windows setup thorw an error

Open yeshan333 opened this issue 1 year ago • 9 comments

Elixir and Erlang/OTP versions

  • Erlang/OTP version is 26.2.5, install by vfox-erlang
  • Elixir windows installer: elixir-otp-26.exe

Operating system

windows

Current behavior

image

when I click elixir-otp-26.exe to install Elixir. then throw an exception:

Found existing Erlang/OTP installation at Elixir Setup Found existing Erlang/OTP installation at C:\Userslyeshan333\.version-foxicachelerlanglv-25.3.2.12lerlang-25.3.2.12\release but checking it exited with error:

Expected behavior

No errors are thrown during installation.

yeshan333 avatar May 18 '24 05:05 yeshan333

@wojtekmach, which check do we execute here? Maybe we can add the check we run in the error message?

josevalim avatar May 18 '24 10:05 josevalim

The error is raised here: https://github.com/elixir-lang/elixir/blob/v1.16.2/lib/elixir/scripts/windows_installer/installer.nsi#L119

based on this check:

https://github.com/elixir-lang/elixir/blob/v1.16.2/lib/elixir/scripts/windows_installer/installer.nsi#L94:L96

It looks like you maybe have OTP 25 installed too so consider uninstalling it first. Though the installer should gracefully handle other installation.

wojtekmach avatar May 20 '24 13:05 wojtekmach

@yeshan333 can you try executing the commands above in your Erlang installation? Does it work? What does it return?

josevalim avatar May 21 '24 11:05 josevalim

After I uninstalled OTP 25, the installer can work normally.

However, if I have multiple OTP versions installed on my machine at the same time, it seems that Elixir's installer cannot find them well.

And OTP 25 installation path exists in the environment variable:

1f42a2cb8e5685186bc8cf4414273bfe @josevalim @wojtekmach

yeshan333 avatar May 21 '24 14:05 yeshan333

Thank you for checking, this is really helpful. What is the installer version, i.e. Elixir version, you used?

wojtekmach avatar May 22 '24 09:05 wojtekmach

Thank you for checking, this is really helpful. What is the installer version, i.e. Elixir version, you used?

installer version is elixir-otp-25.exe.

yeshan333 avatar May 22 '24 13:05 yeshan333

That's not enough information, which release (https://github.com/elixir-lang/elixir/releases) did you download the installer from?

wojtekmach avatar May 22 '24 14:05 wojtekmach

That's not enough information, which release (https://github.com/elixir-lang/elixir/releases) did you download the installer from?

this: https://github.com/elixir-lang/elixir/releases/download/v1.16.3/elixir-otp-25.exe

yeshan333 avatar May 22 '24 14:05 yeshan333

@yeshan333 in the meantime you can handle multiple versions using scoop

scoop install [email protected]
scoop install [email protected]
scoop install [email protected] # becomes the current version
scoop reset [email protected] # change current version

simonmcconnell avatar May 23 '24 01:05 simonmcconnell

Closing this for now. Besides the information above, we are going to include so install scripts on the Elixir website relatively soon. But if you have more updates, please let us know!

josevalim avatar Oct 30 '24 07:10 josevalim