erlef / setup-beam

Set up your BEAM-based GitHub Actions workflow (Erlang, Elixir, Gleam, ...)
MIT License
373 stars 50 forks source link

Could not install Erlang/OTP master from any hex.pm mirror #296

Closed pguyot closed 2 months ago

pguyot commented 2 months ago

Starting today (?), master is no longer available. Restarting the run doesn't work.

See this run: https://github.com/atomvm/AtomVM/actions/runs/9712387604/job/26807073004?pr=1220#step:3:18

Installing Erlang/OTP master - built on amd64/ubuntu-24.04
  aborted
  Waiting 16 seconds before trying again
  aborted
  Waiting 20 seconds before trying again
  Action install Erlang/OTP master failed for mirror https://builds.hex.pm,/ with Error: aborted
  Error: Could not install Erlang/OTP master from any hex.pm mirror

Action is invoked as follows:

    - uses: erlef/setup-beam@v1
      with:
        otp-version: ${{ matrix.otp }}
        elixir-version: ${{ matrix.elixir_version }}

In this run, it fails with matrix.otp and matrix.elixir_version being equal to master with ubuntu-24.04.

        # master version of OTP/Elixir
        - os: "ubuntu-24.04"
          cc: "cc"
          cxx: "c++"
          otp: "master"
          elixir_version: "master"
starbelly commented 2 months ago

I'm surprised master has been working for you, maybe github did you a favor for a while. main should work I believe.

pguyot commented 2 months ago

It worked yesterday. See: https://github.com/atomvm/AtomVM/actions/runs/9695958852/job/26759194572#step:3:20

It seems to me that master specification is also part of setup-beam tests: https://github.com/erlef/setup-beam/blob/e7c76e536ef37c1d9da6a50c70d61d49e0127383/test/setup-beam.test.js#L256

AFAIK, erlang/otp main branch is called master

paulo-ferraz-oliveira commented 2 months ago

Lemme re-run the tests from our main branch. I believe we eventually target erlang/otp master.

paulo-ferraz-oliveira commented 2 months ago

I ran a test over at https://github.com/paulo-ferraz-oliveira/setup-beam-example/actions/runs/9718259064/job/26825721874. Is the result consistent with what you're expecting?

paulo-ferraz-oliveira commented 2 months ago

It seems to me that master specification is also part of setup-beam tests

True, but it's just a unit test, it seems, not representative of an actual install.

I think what @starbelly meant is that Elixir, not Erlang, has no master branch.

Note: I don't know why it says master Erlang is failing, for you, but I can't find a way to replicate it.

paulo-ferraz-oliveira commented 2 months ago

I'ma test with Elixir master and Elixir main. If main passes, but not master, that's expected behaviour. After confirming it's not an action issue, please close it.

pguyot commented 2 months ago

It seems to be a mirror issue as the problem happened for a while and seems to be gone. I don't know where these should be reported, but reliability of this action definitely is a problem.

paulo-ferraz-oliveira commented 2 months ago

reliability of this action definitely is a problem.

We're good to accept pull requests to improve it. 😄

On the other hand, I thought you'd added the mirror option to try and remove some of these obstacles, but here it seems you're using the default mirror (?)

pguyot commented 2 months ago

On the other hand, I thought you'd added the mirror option to try and remove some of these obstacles, but here it seems you're using the default mirror (?)

Indeed. I did create a PR to eventually use this option and also replace as many uses of this action with docker containers which seem to be more reliable for now.

I also took advantage of this conversation to move our elixir tag from master to main since this is what we meant indeed (thank you for pointing that) and master probably will no longer work. I don't know why it did work earlier this week and it no longer does, if it's a change in elixir repo or in hex.pm mirror.

paulo-ferraz-oliveira commented 2 months ago

if it's a change in elixir repo or in hex.pm mirror.

This, probably, @ericmj could reply better.

We're gonna close this issue for now.

We have an identified reliability issue (#260) which is the major (?) source of most issues (that the action's retry mechanism fails) but we've not had time to look at this or somebody that came forward to try and help fix...

ericmj commented 2 months ago

Nothing has changed on builds.hex.pm and the elixir master build is still available but note that the last commit was from 2021. I don't know why you can no longer install it with the action, I can fetch it using curl.

pguyot commented 2 months ago

Looking back at logs, I had more than a dozen of failures related to master, which fall into three categories:

  1. I'm trying to install elixir master with OTP master, but OTP master is no longer compatible. The error is on our end and we need to use Elixir main instead. @starbelly thank you for pointing this.

This happened recently at least six times:

2024-06-29 13:47 UTC https://github.com/pguyot/AtomVM/actions/runs/9724588699/job/26840961455#step:3:1

2024-06-29 06:38 UTC https://github.com/atomvm/AtomVM/actions/runs/9708006302/job/26835971051#step:3:59

2024-06-28 21:28 UTC https://github.com/atomvm/AtomVM/actions/runs/9718629794/job/26826904883#step:3:1

2024-06-28 21:21 UTC https://github.com/atomvm/AtomVM/actions/runs/9708213724/job/26826898695#step:3:59

2024-06-28 18:33 UTC https://github.com/atomvm/AtomVM/actions/runs/9717081476/job/26822010141#step:3:1

2024-06-28 12:26 UTC https://github.com/atomvm/AtomVM/actions/runs/9709927629/job/26808118306#step:3:61

  1. Erlang/OTP failed to install for no reason (what I described here)

This happened recently at least once:

2024-06-28 12:07 UTC https://github.com/atomvm/AtomVM/actions/runs/9712387604/job/26807073004#step:3:24

  1. Elixir master failed to install for no reason (same problem as described here for Erlang/OTP, but after Erlang/OTP was properly installed)

This happened recently at least fourteen times:

2024-06-28 09:43 UTC https://github.com/atomvm/AtomVM/actions/runs/9709927629/job/26802253744#step:3:31

2024-06-28 09:09 UTC https://github.com/atomvm/AtomVM/actions/runs/9709927629/job/26800400981#step:3:31

2024-06-28 08:38 UTC https://github.com/atomvm/AtomVM/actions/runs/9709927629/job/26799589335#step:3:31

2024-06-28 07:07 UTC https://github.com/atomvm/AtomVM/actions/runs/9708213724/job/26796448990#step:3:31

2024-06-28 06:46 UTC https://github.com/atomvm/AtomVM/actions/runs/9708213724/job/26795840812#step:3:31

2024-06-28 06:27 UTC https://github.com/atomvm/AtomVM/actions/runs/9708213724/job/26795312841#step:3:31

2024-06-28 06:08 UTC https://github.com/atomvm/AtomVM/actions/runs/9708213724/job/26794662774#step:3:31

2024-06-28 05:44 UTC https://github.com/atomvm/AtomVM/actions/runs/9708006302/job/26794096276#step:3:31

2024-06-28 00:41 UTC https://github.com/atomvm/AtomVM/actions/runs/9705547106/job/26787815080#step:3:31

2024-06-27 23:12 UTC https://github.com/atomvm/AtomVM/actions/runs/9704773893/job/26785640283#step:3:31

2024-06-27 22:48 UTC https://github.com/atomvm/AtomVM/actions/runs/9704593971/job/26785111819#step:3:31

2024-06-27 21:40 UTC https://github.com/atomvm/AtomVM/actions/runs/9703489507/job/26783040319#step:3:31

2024-06-27 21:22 UTC https://github.com/atomvm/AtomVM/actions/runs/9703634973/job/26782209886#step:3:31

2024-06-27 21:02 UTC https://github.com/atomvm/AtomVM/actions/runs/9703489507/job/26781758193#step:3:31

ericmj commented 2 months ago

I think what would be helpful is if the action gives some indication why it failed. Did builds.txt fail to fetch, is the requested version missing in builds.txt, did the elixir/erlang zip/tar fail to fetch, etc.

starbelly commented 2 months ago

I think what would be helpful is if the action gives some indication why it failed. Did builds.txt fail to fetch, is the requested version missing in builds.txt, did the elixir/erlang zip/tar fail to fetch, etc.

Agreed. There's a lot of simple changes that can be done to make produce diagnostics information.