CircleCI-Public / cimg-elixir

The CircleCI Elixir Docker Convenience Image.
https://circleci.com/developer/images/image/cimg/elixir
MIT License
4 stars 17 forks source link

Bug Report: wrong elixir version installed in cimg/elixir v1.16.x and v1.17.x #156

Open lwld opened 4 months ago

lwld commented 4 months ago

Describe the bug

All cimg/elixir images tagged with patch versions of 1.16 and 1.17 contain the wrong elixir version (patch .0 instead of what is tagged):

It seems that the elixir version was never updated when these images were published.

Images tagged with 1.15.8 are still correct, they contain elixir version 1.15.8.

Tested with -erlang-26.2.1 images.

To Reproduce

Minimal sample project that reproduces the issue: https://github.com/Kittysplit/cimg_test The build results on commits show which tag versions are correct and which aren't: https://github.com/Kittysplit/cimg_test/commits/main/

Sample config:

version: 2.1

workflows:
  check:
    jobs:
      - compile

jobs:
  compile:
    docker:
      - image: cimg/elixir:1.17.2-erlang-26.2.1
    steps:
      - checkout
      - run:
          name: "Check elixir version"
          command: elixir --version
      - run:
          name: "Install hex"
          command: mix local.hex --force
      - run:
          name: "Install rebar"
          command: mix local.rebar --force
      - run:
          name: "Get elixir dependencies"
          command: mix deps.get
      - run:
          name: "Build elixir"
          command: mix compile --warnings-as-errors
      - run:
          name: "Run elixir tests"
          command: mix test

The elixir --version step output already shows that it's running the wrong elixir version:

Erlang/OTP 26 [erts-14.2.1] [source] [64-bit] [smp:36:8] [ds:36:8:10] [async-threads:1] [jit:ns]

Elixir 1.17.0 (compiled with Erlang/OTP 26)

If it contains an elixir project and the elixir version is fixed including patch version (with elixir: "~> 1.17.2"), mix compile / mix test will fail with ** (Mix) You're trying to run :cimg_test on Elixir v1.17.0 but it has declared in its mix.exs file it supports only Elixir ~> 1.17.2. See sample project linked above to reproduce.

Expected behavior

Images should contain the tagged elixir version, or higher patch version for images tagged with only a minor release (as described in https://github.com/CircleCI-Public/cimg-elixir?tab=readme-ov-file#tagging-scheme)

Workarounds

Screenshots and Build Links

Screenshots:

See elixir version in image container tag during spin up vs elixir --version output:

Screenshot 2024-07-12 at 17 29 32

Error on mix compile:

Screenshot 2024-07-12 at 17 29 44

Additional context none

tomtaylor commented 3 months ago

This seems like a pretty big issue - is anyone at CircleCI able to look at this? Thanks! cc: @bjohnso5

Kuret commented 1 month ago

@bjohnso5 Any update on this? There has not been a response on this issue and the OTP27 issue for more than a month.

I know I am not obligated anything (even though we pay for and use CircleCI heavily in our organization), but not even an acknowledgement for issues on an officially supported CircleCI convenience image is disappointing to say the least.

If maintaining this is difficult or there is a lack of resources wouldn't it be preferable to drop support or hand it over to someone else in the community, so developers that prefer to be on top of version updates know not to rely on this 'convenience' image?

Kuret commented 4 weeks ago

@bjohnso5 @FelicianoTech (not sure who to tag for this) any update on this? This (and the OTP27 issue) is blocking our version updates. Once again, not even an acknowledgement is disappointing.

My colleague also made an attempt (that also got no response it seems) but just upping the versions didn't seem to work: https://github.com/CircleCI-Public/cimg-elixir/pull/160

Once again, does CircleCI still plan on 'officially' supporting this image or do we have to look elsewhere? I'd rather use an official image in our CI flow...

tomtaylor commented 4 weeks ago

@Kuret it might be worth going through support to get an answer about whether this image is officially supported, and what the release schedule is. The CircleCI docs suggest this is an officially supported image, but the radio silence suggests it's on a best-effort basis. https://circleci.com/docs/circleci-images/

tomtaylor commented 4 weeks ago

FWIW, I think it wouldn't be too hard to switch to e.g. the hex.pm docker image, but we use some of the CircleCI CLI tools provided in the image and I haven't had the time to work out how to layer the two together.

Kuret commented 4 weeks ago

Their support options are kind of confusing... I tried to create a ticket through our organization but couldn't find much. I could only find a support site where I had to create a separate account (so not through my account/organization).

I created a post on their 'Discuss' page for now: https://discuss.circleci.com/t/please-clarify-your-offical-cimg-elixir-support/52212

Kuret commented 3 weeks ago

No response on GitHub No response on their forums No response on our support ticket. Our organization's plan says 'Prompt responses' under the support section. I'm not sure what CircleCI would define as 'prompt' but it's not in line with the general expectation.

What kind of organization is this?

@bjohnso5 or @FelicianoTech can you please get someone at CircleCI to look into this? And look into our ticket?

FelicianoTech commented 3 days ago

I haven't worked at CircleCI since last January. I can't help with this. Sorry.