-
Notifications
You must be signed in to change notification settings - Fork 1k
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
Erlang/OTP 23 Support #3115
Comments
Another problem is that we currently have a lot of this kind of compiler warning:
But we can't replace those with the new try/catch syntax while we need to support versions previous to OTP 21. However, that same thread shows some workarounds that we could presumably use to patch all the existing incompatible code. |
Having to stick macros in all over the code does sound like a bit of a pain, unless it can be done with a find/replace without breaking everything. I have basically zero knowledge of Erlang or how it works, but I do find it a bit strange that they'd remove existing syntax, and expect dependant projects to keep up. Unless it's common for Erlang projects to only support specific OTP versions? |
Another option is to deprecate erlang prior to 21. However it could be a tougher call because I think we have platforms which do not support 21 yet. Our current position is expressed here #2934 (comment). |
@iilyak My understanding from IBM is that there have been issues in production with Erlang 21+, which is why the official binary packages we have on couchdb.org are built against 20.3.8.latest. If you or @rnewson or @davisp have updated info as to what's safe to move to, we could consider moving ahead, but the earliest would be 3.2.0. The impending 3.1.1 patch release would be too minor to change Erlang versions. |
The only known bad versions I know of were explicitly excluded in the
rebar.config.script.
…On Mon, Aug 31, 2020 at 10:25 AM Joan Touzet ***@***.***> wrote:
@iilyak <https://github.com/iilyak> My understanding from IBM is that
there have been issues in production with Erlang 21+, which is why the
official binary packages we have on couchdb.org are built against
20.3.8.latest. If you or @rnewson <https://github.com/rnewson> or @davisp
<https://github.com/davisp> have updated info as to what's safe to move
to, we could consider moving ahead, but the earliest would be *3.2.0*.
The impending 3.1.1 patch release would be too minor to change Erlang
versions.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#3115 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AAAE3WLVBFJTVHIAXZCQXUDSDO6GZANCNFSM4QPXHR7A>
.
|
FYI:
|
Keep in mind that couch_log need to be updated as well to match the changes in OTP logging infrastructure. I did a test and logging of crashes from gen_server doesn't work on otp 22 and I am sure wouldn't be working on 23 without changes. |
I’ve started digging through these.
diff --git a/src/rebar_port_compiler.erl b/src/rebar_port_compiler.erl
index 9679c80..44f7b0d 100644
--- a/src/rebar_port_compiler.erl
+++ b/src/rebar_port_compiler.erl
@@ -673,7 +673,7 @@ default_env() ->
"\" "
])},
{"ERL_EI_LIBDIR", lists:concat(["\"", erl_interface_dir(lib), "\""])},
- {"ERL_LDFLAGS" , " -L$ERL_EI_LIBDIR -lerl_interface -lei"},
+ {"ERL_LDFLAGS" , " -L$ERL_EI_LIBDIR -lei"},
{"ERLANG_ARCH" , rebar_utils:wordsize()},
{"ERLANG_TARGET", rebar_utils:get_arch()},
diff --git a/rebar.config b/rebar.config
index 1785295..250cd2a 100644
--- a/rebar.config
+++ b/rebar.config
@@ -1,4 +1,4 @@
-{require_otp_vsn, "R14|R15|R16|17|18|19|20|21|22"}.
+{require_otp_vsn, "R14|R15|R16|17|18|19|20|21|22|23"}.
{erl_opts, [debug_info, warn_unused_vars, warn_shadow_vars, warn_unused_import]}.
{port_sources, ["c_src/*.cc", — That’s as far as I got this time around. |
I gave this a spin and with the changes outlined here on 3.x, I got @iilyak Do you have more pointers on the logging behaviour. I found this reference in the Erlang 22 release notes:
— https://www.erlang.org/news/132 But I’m not sure if that’s what you mean. |
Erlang 20 is now fixed: 70334b3#diff-a07a3d3b357a34c4acb80b2e178e9a19e6c2ed9d91cb0aa8d53cadabb1ae8bd0R95 This is mainly a draft to show how it can be done. I’m happy to see a bike shed about making this cleaner. I’m a bit confused tho, this broke builds tagged with 21 and 22, but I didn’t dig too deep in it. Are we sure our per-version builds are actually using the versions they say they do? |
I don't see it, our PRs currently build against 20.3.8.11, 20.3.8.25 and 22.2.3. We don't build against any 21 in Jenkins and we don't have 23 in Jenkins yet. |
@wohali agreed that the logs show that now, there was just some intermittent state there when they were failing. The UI there is also not very intuitive, so I may have turned myself around. |
@wohali good idea. I will do that. Beforehand I think we may want to clean up some of the applications in |
We have OTP 23 support now in both main and 3.x branches. I think we can close this |
Summary
Would it be possible to add support for OTP 23?
Desired Behaviour
Support for building/running CouchDB with OTP 23.
Possible Solution
I tried just adding the appropriate version numbers to
rebar.config.script
as was done in #2070, but the build fails when attempting to linkb64url
.Some deprecated parts of
erl_interface
were removed in OTP 23 (https://www.erlang.org/news/140).There may, or course, be further incompatibilities.
Additional context
Void Linux has moved on to OTP 23.
The text was updated successfully, but these errors were encountered: