[erlang-questions] FW: Version numbering scheme change and the implication / Re: [ANN] Erlang/OTP 17.0-rc1 has been released.

Rickard Green <>
Tue Feb 18 13:42:20 CET 2014


We've decided not to add an erlang:system_info(otp_version), not to
add an -otp_version command line argument to erl, and to remove the
erlang:system_info(otp_correction_package) that is part of OTP
17.0-rc1. Instead we will add a text-file OTP_VERSION which will
contain current OTP version. Info about the OTP_VERSION file will be
documented in the documentation of erlang:system_info(otp_release)
(see below).

The upcoming documentation of erlang:system_info(otp_release) :

    Returns a string containing the OTP release number of the OTP release
    that the currently executing ERTS application is part of.

    As of OTP release 17, the OTP release number corresponds to the major
    OTP version number. The OTP version as a concept was introduced in
    OTP 17.

    There is no erlang:system_info() argument giving the exact OTP version.
    This since the exact OTP version in the general case is hard to
    determine. In an OTP source code tree as well as in an installed OTP
    development system, the OTP version can be read from the text file
    OTP_VERSION in the code:root_dir() directory.

    If the version read from the OTP_VERSION file in a development system
    has a ** suffix, the system has been patched using the
    '$ERL_TOP/otp_build patch_app' tool. In this case, the system consists
    of parts from multiple OTP versions. The version preceding the ** suffix
    corresponds to the OTP version of the base system that has been
    patched.

    On a target system (see the system principles documentation) no
    OTP_VERSION file will exist. This since one easily can create a target
    system where it is hard to even determine the base OTP version.

    Note that if a development system is updated by other means than
    '$ERL_TOP/otp_build patch_app', the OTP_VERSION file may
    erroneously identify an exact OTP version.



Regards,
RIckard Green, Erlang/OTP, Ericsson AB


On Thu, Feb 13, 2014 at 5:49 PM, Vlad Dumitrescu <> wrote:
> On Thu, Feb 13, 2014 at 5:41 PM, Fred Hebert <> wrote:
>> → erl -noshell -eval 'io:format("~s~n",[erlang:system_info(otp_correction_package)]),halt(0).'
>> 17.0-rc1
>>
>> It is objectively longer than having -V switch, loads more content, but
>> gets the result you want as one command line option. Adding in the
>> options '-noinput +A 0 -smp disable' to the command brings it below
>> 0.15s on my VPS, usually below something noticeable.
>
> Thanks, but my use case is to have a number of erlang installations
> and detect which version each is (looking at the directory name
> doesn't always help). 0.15s*5 is noticeable and it's not that fast on
> all filesystems (think clearcase)... Of course, I have this workaround
> as backup. The issue is that the information was available before, but
> is going away now with the new version scheme.
>
> regards,
> Vlad
> _______________________________________________
> erlang-questions mailing list
> 
> http://erlang.org/mailman/listinfo/erlang-questions



More information about the erlang-questions mailing list