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

Latest update appears to break asdf install #90

Closed
dobs opened this issue Sep 16, 2020 · 7 comments
Closed

Latest update appears to break asdf install #90

dobs opened this issue Sep 16, 2020 · 7 comments

Comments

@dobs
Copy link
Contributor

dobs commented Sep 16, 2020

Example .tool-versions contents:

erlang 22.1
elixir 1.9.4-otp-22

We're seeing reproduce-able failures in a project where Elixir previously installed successfully by running:

asdf uninstall elixir 1.9.4-otp-22
asdf plugin-update elixir
asdf install

Locally the failures look like:

erlang 22.1 is already installed
==> Checking whether specified Elixir release exists...
==> Downloading 1.9.4-otp-22 to /var/folders/8t/bcy9yfg90c56_4m_36wmtyrm0000gp/T//elixir-precompiled-1.9.4-otp-22.zip
** Resuming transfer from byte position 5274462
  % Total    % Received % Xferd  Average Speed   Time    Time     Time  Current
                                 Dload  Upload   Total   Spent    Left  Speed
  0     0    0     0    0     0      0      0 --:--:-- --:--:-- --:--:--     0
==> Copying release into place
asdf: No version set for command elixir
you might want to add one of the following in your .tool-versions file:

elixir 1.6.1
elixir 1.6.5
elixir 1.6.6
elixir 1.7.3
elixir 1.7.4-otp-21
elixir v1.6.1
elixir v1.7.4
elixir 1.7.3-otp-21
elixir 1.9.1
elixir 1.8
asdf: No version set for command elixir
you might want to add one of the following in your .tool-versions file:

elixir 1.6.1
elixir 1.6.5
elixir 1.6.6
elixir 1.7.3
elixir 1.7.4-otp-21
elixir v1.6.1
elixir v1.7.4
elixir 1.7.3-otp-21
elixir 1.9.1
elixir 1.8

And on CircleCI:

==> Copying release into place
/usr/bin/env: 'elixir': No such file or directory
/usr/bin/env: 'elixir': No such file or directory

My current hunch is that this relates to the double mix lines here, as it would explain the duplicate error messages: e7e9e5d#diff-81fd2adb13518cfcf88c004b912c4d9fR22

@benrom
Copy link

benrom commented Sep 17, 2020

I manually installed elixir this way:

  • extract the zip folder listed in the output from the temp folder (here /var/folders/8t/bcy9yfg90c56_4m_36wmtyrm0000gp/T//elixir-precompiled-1.9.4-otp-22.zip)
  • copy its content to ~/.asdf/installs/elixir/1.9.4-otp-22 (with the folder name being the version you were trying to install)
  • run cp ~/.asdf/shims/erlang ~/.asdf/shims/elixir
  • edit ~/.asdf/shims/elixir and replace erlang with elixir -- I also updated the comment with the version (not sure it's parsed)
  • run cp ~/.asdf/shims/elixir ~/.asdf/shims/mix
  • edit ~/.asdf/shims/mix and replace elixir with mix

Now you should have mix and elixir available.
You can do mix local.hex and mix local.rebar to be ready to go.

@dvic
Copy link

dvic commented Sep 17, 2020

This is also breaking our CI pipeline, is there a way to install the previous commit with ASDF? (Apart from forking and manually reverting the commit)

@eamontaaffe
Copy link

eamontaaffe commented Sep 17, 2020

@dvic it looks like you are unable to select a version for the plugins: asdf-vm/asdf#166

This is breaking our CI pipeline too 😢.

@sneako
Copy link

sneako commented Sep 17, 2020

Also seeing this behaviour, but I was able to successfully install after checking out the last commit before yesterday's release:

cd ~/.asdf/plugins/elixir
git checkout 254fec762111c89f11a947d15f4d7af24f80efab

@dobs
Copy link
Contributor Author

dobs commented Sep 17, 2020

@dvic We've forked for the time being, but adding a line like the one @sneako provided to your CI steps should also work as a temporary workaround.

Making the git ref a CI parameter (defaulting to master) might be a good future-proofing step.

@dvic
Copy link

dvic commented Sep 17, 2020

@sneako @dobs nice workaround, easier than forking, will use that, thanks!

@dobs
Copy link
Contributor Author

dobs commented Sep 17, 2020

Quick followup, the revert PR has been accepted so things should be working again.

@dobs dobs closed this as completed Sep 17, 2020
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

No branches or pull requests

5 participants