-
Notifications
You must be signed in to change notification settings - Fork 63
Override OTP version when specified in Elixir spec #330
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
Override OTP version when specified in Elixir spec #330
Conversation
src/setup-beam.js
Outdated
const userSuppliedOtp = exSpec0.match(/-otp-(\d+)/)?.[1] ?? null | ||
|
||
if (userSuppliedOtp && isVersion(userSuppliedOtp) && userSuppliedOtp !== otpVersionMajor) { | ||
8000 | core.warning(`Elixir built for Erlang/OTP ${userSuppliedOtp} does not match the specified Erlang/OTP version ${otpVersionMajor}`) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I guess this is subjective but to me this is not a warning, it's a feature not a bug. Btw, does the warning appear in tests? do we have something like ExUnit.CaptureLog?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yes, the warning shows up in the test but also all debug messages. I found this actions/toolkit#118 but it seems there is no built in way to capture the log for a single test case.
I have no preference if we want to handle it silently or warn the user that they have a mismatch. Just let me know what works best for you.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Yeah, please remove the warning. We can always add it later.
591632b
to
fc46e54
Compare
@paulo-ferraz-oliveira let's ship this? At the moment there's no way to pick Elixir with OTP 28. Upcoming Elixir 1.19 will be precompiled against it but we shouldn't wait for it IMHO, I think it is entirely reasonable for folks to pick, say, |
@wojtekmach, I'm Ok to ship it. I was just expecting CI to pass. |
What's probably failing here is that |
fc46e54
to
3155eef
Compare
Ah my bad! I thought the |
Argh, CI's now failing because of |
I've created a draft (for now) PR: #331. This'll hopefully remove the issues with testing around the latest |
#331 proposes changes to fix the tests. I think it'd be best to rebase this one and release only after that one's merged... |
3155eef
to
abfd95a
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM
This change was released in v1.19.0, also tagged |
Description
When specifying an Elixir version like
1.18.4-otp-27
and OTP version28.0
the action would overwrite this to1.18.4-otp-28
which does not exist, although the versions are compatible. This fixes the issue by overriding the OTP major version when specified in the specCloses #329 .