| Initial Release | OTP 27.0 |
| Git Tag | OTP-27.0 |
| Date | 2024-05-20 |
| Issue Id |
BL-312
BL-322
ERIERL-43
ERIERL-964
ERIERL-967
ERIERL-985
|
| System | OTP |
| Release | 27 |
| Application |
|
| Potential Incompatibilities |
Highlights #
- OTP-18606
-
- Application(s):
- public_key, ssl
- Related Id(s):
-
OTP-16448, OTP-16875
The
sslclient can negotiate and handle certificate status request (OCSP stapling support on the client side).Thanks to voltone for interop testing and related discussions.
- OTP-18622
-
The functions
is_equal/2,map/2, andfiltermap/2have been added to the modulessets,ordsets, andgb_sets. - OTP-18648
-
- Application(s):
- compiler, stdlib
- Related Id(s):
The compiler now emits nicer error message for function head mismatches. For example, given:
a() -> ok; a(_) -> error.Erlang/OTP 26 and earlier would emit a diagnostic similar to:
t.erl:6:1: head mismatch % 6| a(_) -> error. % | ^while in Erlang/OTP 27 the diagnostic is similar to:
t.erl:6:1: head mismatch: function a with arities 0 and 1 is regarded as two distinct functions. Is the number of arguments incorrect or is the semicolon in a/0 unwanted? % 6| a(_) -> error. % | ^ - OTP-18680
-
The compiler will now merge consecutive updates of the same record.
As an example, the body of the following function will be combined into a single tuple creation instruction:
-record(r, {a,b,c,d}). update(Value) -> R0 = #r{}, R1 = R0#r{a=Value}, R2 = R1#r{b=2}, R2#r{c=3}. - OTP-18717
-
- POTENTIAL INCOMPATIBILITY
As announced in OTP 26.1,
0.0is no longer considered equivalent to-0.0when using the term equivalence operators (=:=and=/=).The arithmetic equality operators (
==and/=) and all relative comparison operations still consider0.0equal to-0.0. - OTP-18744
-
- Application(s):
- erts
- Related Id(s):
The
erlcommand now supports the-Sflag, which is similar to the-runflag, except that it will pass all arguments up to end of the command line to the called function. (The-runflag will not pass arguments beginning with a hyphen.) Another difference is that-Swill always call a function with one argument, passing an empty list if no arguments were given. - OTP-18750
-
- POTENTIAL INCOMPATIBILITY
Triple-Quoted Strings has been implemented as per EEP 64. See String in the Reference Manual.
Example:
1> """ a b c """. "a\nb\nc"Adjacent string literals without intervening white space is now a syntax error, to avoid possible confusion with triple-quoted strings. For example:
1> "abc""xyz". "xyz". * 1:6: adjacent string literals without intervening white space - OTP-18756
-
- Application(s):
- tools
- Related Id(s):
There is a new tool
tprof, which combines the functionality ofeprofandcprofunder one interface and adds heap profiling. It also has functionality to help with profiling process hierarchies.Example:
1> tprof:profile(lists, seq, [1, 16], #{type => call_memory}). ****** Process <0.92.0> -- 100.00% of total *** FUNCTION CALLS WORDS PER CALL [ %] lists:seq_loop/3 5 32 6.40 [100.00] 32 [ 100.0] ok - OTP-18808
-
- Application(s):
- stdlib
- Related Id(s):
Several new functions that accept funs have been added to module
timer.Functions
apply_after/2,apply_interval/2, andapply_repeatedly/2accept a nullary fun as the second argument, while functionsapply_after/3,apply_interval/3, andapply_repeatedly/3accept an n-ary fun as the second and a list of n arguments for the fun as the third argument. - OTP-18825
-
- Application(s):
- stdlib
- Related Id(s):
-
PR-7684, OTP-18750
Sigils on string literals have been implemented as per EEP 66, that is: binary and string sigils in verbatim and escape characters variants, as well as a default (vanilla) Sigil. All for ordinary strings and for triple-quoted strings (EEP 64). See Sigils in the Reference Manual.
Examples:
1> ~"Björn". <<"Björn"/utf8>> 2> ~b"Björn". <<"Björn"/utf8>> 3> ~S"\s*(\w+)". "\\s*(\\w+)" 4> ~B"\s*(\w+)". <<"\\s*(\\w+)">> - OTP-18856
-
- Application(s):
- compiler, erts, kernel, tools
- Related Id(s):
Native coverage support has been implemented in the JIT. It will automatically be used by the
covertool to reduce the execution overhead when running cover-compiled code.There are also new APIs to support native coverage without using the
covertool.To instrument code for native coverage it must be compiled with the
line_coverageoption.To enable native coverage in the runtime system, start it like so:
$ erl +JPcover trueThere are also the following new functions for supporting native coverage:
code:coverage_support/0code:get_coverage/2code:reset_coverage/1code:get_coverage_mode/0code:get_coverage_mode/1code:set_coverage_mode/1
- OTP-18916
-
- Application(s):
- compiler, stdlib
- Related Id(s):
EEP-59 - Documentation Attributes has been implemented.
Documentation attributes can be used to document functions, types, callbacks, and modules. The keyword
-moduledoc "Documentation here".is used to document modules, while-doc "Documentation here".can be used on top of functions, types, and callbacks to document them, respectively.- Types, callbacks, and function documentation can be set to
hiddeneither via-doc falseor-doc hidden. When documentation attributes mark a type as hidden, they will not be part of the documentation. - The documentation from
moduledocanddocgets added by default to the binary beam file, following the format of EEP-48. - Using the compiler flag
warn_missing_docwill raise a warning when-docattributes are missing in exported functions, types, and callbacks. - Using the compiler flag
warn_missing_spec_documentedwill raise a warning when spec attributes are missing in documented functions, types, and callbacks. moduledocs anddocs may refer to external files to be embedded, such as-doc {file, "README.md"}., which refers to the fileREADME.mdfound in the current working directory.- The compiler warns about exported functions whose specs refer to hidden types. Thus, there will be warnings when a hidden type (meaning, the type is not part of the documentation) gets used in an exported function.
- OTP-18923
-
- Application(s):
- stdlib
- Related Id(s):
New
etsfunctionsets:first_lookup/1,ets:next_lookup/2,ets:prev_lookup/2andets:last_lookup/1. Example:ets:next_lookup/1is equivalent toets:next/2followed byets:lookup/2with the next key. The new combined functions are more efficient and with guaranteed atomicity. - OTP-18944
-
- Application(s):
- otp, stdlib
- Related Id(s):
The
maybeexpression is now enabled by default.To use
maybeas an atom, it needs to be single-quoted. Alternatively, themaybeexpression can be disabled by disabling themaybe_exprfeature. That can be done by placing the following the line at the beginning of an Erlang source file:-feature(maybe_expr, disable).Another way to disable the
maybe_exprfeature is by passing the-disable-featureoption toerlc:erlc -disable-feature maybe_expr some_file.erl - OTP-18955
-
- Application(s):
- asn1, common_test, compiler, crypto, debugger, dialyzer, diameter, edoc, eldap, erl_interface, erts, et, eunit, ftp, inets, jinterface, kernel, megaco, mnesia, observer, odbc, os_mon, parsetools, public_key, reltool, runtime_tools, sasl, snmp, ssh, ssl, stdlib, syntax_tools, tftp, tools, wx, xmerl
- Related Id(s):
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18972
-
- Application(s):
- compiler, erts
- Related Id(s):
Safe destructive update of tuples has been implemented in the compiler and runtime system. This allows the VM to update tuples in-place when it is safe to do so, thus improving performance by doing less copying but also by producing less garbage.
Example:
-record(rec, {a,b,c}). update(#rec{a=needs_update,b=N}=R0) -> R = R0#rec{a=up_to_date}, if N < 0 -> R#rec{c=negative}; N == 0 -> R#rec{c=zero}; N > 0 -> R#rec{c=positive} end.The record updates in each of the three clauses of the
ifcan safely be done in-place, because variableRis not used again. - OTP-18980
-
- Application(s):
- erts, kernel
There is a new module
tracein Kernel providing the same trace functionality aserlang:trace/3anderlang:trace_pattern/3, but with the addition of dynamic isolated trace sessions. - OTP-19018
-
- Application(s):
- asn1
- Related Id(s):
The
jer(JSON Encoding Rules) for ASN.1 now use the newjsonmodule for encoding and decoding JSON. Thus, there is no longer any need for an external JSON library. - OTP-19020
-
- Application(s):
- stdlib
- Related Id(s):
There is a new module
jsonfor encoding and decoding JSON.Both encoding and decoding can be customized. Decoding can be done in a SAX-like fashion and handle multiple documents and streams of data.
- OTP-19025
-
- POTENTIAL INCOMPATIBILITY
For security reasons, the CBC ciphers are now longer included in the list of default ciphers for TLS-1.2.
Potential Incompatibilities #
- OTP-18594
-
- Application(s):
- erts
- Related Id(s):
The
pidfield returned fromerlang:fun_info/1,2is now always the pid for theinitprocess of the local node, not the pid for the actual process that created the fun. - OTP-18639
-
- Application(s):
- erts
- Related Id(s):
By default, escripts will now be compiled instead of interpreted. That means that the
compilerapplication must be installed. - OTP-18641
-
- Application(s):
- inets
- Related Id(s):
Introduced a default value for httpd_server name configuration to improve ease of use.
- OTP-18717
-
- HIGHLIGHT
As announced in OTP 26.1,
0.0is no longer considered equivalent to-0.0when using the term equivalence operators (=:=and=/=).The arithmetic equality operators (
==and/=) and all relative comparison operations still consider0.0equal to-0.0. - OTP-18750
-
- HIGHLIGHT
Triple-Quoted Strings has been implemented as per EEP 64. See String in the Reference Manual.
Example:
1> """ a b c """. "a\nb\nc"Adjacent string literals without intervening white space is now a syntax error, to avoid possible confusion with triple-quoted strings. For example:
1> "abc""xyz". "xyz". * 1:6: adjacent string literals without intervening white space - OTP-18784
-
The documentation for the preprocessor now mentions that
defined(Name)can be called in the condition for an-ifor-elifdirective to test whetherNameis the name of a defined macro. (This feature was implemented in OTP 21.)If a function call in an
-ifor-elifwith a name that is not the name of a guard BIF, there would not be a compilation error, but would instead cause the lines following the directive to be skipped. This has now been changed to be a compilation error. - OTP-18966
-
- Application(s):
- kernel, otp
- Related Id(s):
The existing experimental support for archive files will be changed in a future release. The support for having an archive in an escript will remain, but the support for using archives in a release will either become more limited or completely removed.
As of Erlang/OTP 27, the function
code:lib_dir/2, the-code_path_choiceflag, and usingerl_prim_loaderfor reading members of an archive are deprecated.To remain compatible with future version of Erlang/OTP
escriptscripts that need to retrieve data files from its archive should useescript:extract/2instead oferl_prim_loaderandcode:lib_dir/2. - OTP-18968
-
The order in which the compiler looks up options has changed.
When there is a conflict in the compiler options given in the
-compile()attribute and options given to the compiler, the options given in the-compile()attribute overrides the option given to the compiler, which in turn overrides options given in theERL_COMPILER_OPTIONSenvironment variable.Example:
If
some_module.erlhas the following attribute:-compile([nowarn_missing_spec]).and the compiler is invoked like so:
% erlc +warn_missing_spec some_module.erlno warnings will be issued for functions that do not have any specs.
- OTP-19016
-
- Application(s):
- crypto, public_key
- Related Id(s):
The existing function
ssl:key_exporter_materials/4is now documented and supported. - OTP-19022
-
- Application(s):
- inets
The implementations of
http_uri:encode/1andhttp_uri:decode/1are now replaced with their equivalent, but bug free versions from moduleuri_string, namelyuri_string:quote/1anduri_string:unquote/1. - OTP-19025
-
- HIGHLIGHT
For security reasons, the CBC ciphers are now longer included in the list of default ciphers for TLS-1.2.
- OTP-19029
-
- Application(s):
- stdlib
- Related Id(s):
The error handling the
simple_one_for_onesupervisor has been enhanced. A transient child returningignorewill no longer cause a crash.Also, automatic shutdown has been disabled because it does not make sense for this supervisor type. That is was allowed is considered a bug. Therefore, we don’t consider this an incompatible change.
- OTP-19075
-
- Application(s):
- crypto, public_key
Due to another attack on PKCS #1 v1.5 padding, known as the Marvin attack, about which we were alerted by Hubert Kario from Red Hat. You can find more details about the attack at https://people.redhat.com/~hkario/marvin/ Functions that may be vulnerable are now deprecated.
Note that you might mitigate the problem by using appropriate versions of OpenSSL together with our software, but we recommend not using them at all.
Also avoid using TLS versions prior to TLS-1.2 (not supported by default) and do not enable RSA-key exchange cipher suites (not supported by default).
- OTP-19079
-
- Application(s):
- xmerl
- Related Id(s):
Some default values in Xmerl has been changed to avoid XML External Entity (XXE) vulnerabilities if you’re parsing untrusted XML.
xmerl_scan: the default value for allow_entities has changed to false. xmerl_sax_parser: the default value for external_entities has changed to none.
OTP-27.0 #
- OTP-18717
-
- HIGHLIGHT, POTENTIAL INCOMPATIBILITY
As announced in OTP 26.1,
0.0is no longer considered equivalent to-0.0when using the term equivalence operators (=:=and=/=).The arithmetic equality operators (
==and/=) and all relative comparison operations still consider0.0equal to-0.0. - OTP-18784
-
- POTENTIAL INCOMPATIBILITY
The documentation for the preprocessor now mentions that
defined(Name)can be called in the condition for an-ifor-elifdirective to test whetherNameis the name of a defined macro. (This feature was implemented in OTP 21.)If a function call in an
-ifor-elifwith a name that is not the name of a guard BIF, there would not be a compilation error, but would instead cause the lines following the directive to be skipped. This has now been changed to be a compilation error. - OTP-18943
-
configurescripts of the OTP build system are now generated using Autoconf 2.72. - OTP-18944
-
- HIGHLIGHT
The
maybeexpression is now enabled by default.To use
maybeas an atom, it needs to be single-quoted. Alternatively, themaybeexpression can be disabled by disabling themaybe_exprfeature. That can be done by placing the following the line at the beginning of an Erlang source file:-feature(maybe_expr, disable).Another way to disable the
maybe_exprfeature is by passing the-disable-featureoption toerlc:erlc -disable-feature maybe_expr some_file.erl - OTP-18965
-
- Related Id(s):
By default
configurescripts used when building OTP will now try to enable support for timestamps that will work after mid-January 2038. This has typically only been an issue on 32-bit platforms.If
configurecannot figure out how to enable such timestamps, it will abort with an error message. If you want to build the system anyway, knowing that the system will not function properly after mid-January 2038, you can pass the--disable-year2038option toconfigure, which will enableconfigureto continue without support for timestamps after mid-January 2038. - OTP-18966
-
- POTENTIAL INCOMPATIBILITY
The existing experimental support for archive files will be changed in a future release. The support for having an archive in an escript will remain, but the support for using archives in a release will either become more limited or completely removed.
As of Erlang/OTP 27, the function
code:lib_dir/2, the-code_path_choiceflag, and usingerl_prim_loaderfor reading members of an archive are deprecated.To remain compatible with future version of Erlang/OTP
escriptscripts that need to retrieve data files from its archive should useescript:extract/2instead oferl_prim_loaderandcode:lib_dir/2. - OTP-18995
-
The restriction for the expression that gives a default value for a record field is now documented.
asn1-5.3 #
- OTP-18813
-
- Related Id(s):
Multiple bugs has been eliminated in the specialized decode feature.
- OTP-18804
-
- Related Id(s):
Specs have been added to all
asn1ctAPI functions. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19018
-
- HIGHLIGHT
The
jer(JSON Encoding Rules) for ASN.1 now use the newjsonmodule for encoding and decoding JSON. Thus, there is no longer any need for an external JSON library.
Full runtime dependencies of asn1-5.3
erts-14.0, kernel-9.0, stdlib-5.0
common_test-1.27 #
- OTP-18658
-
- Related Id(s):
Calls to
ct:capture_start/0andct:capture_stop/0are now synchronous to ensure that all output is captured. - OTP-18682
-
The order in which multiple hooks are executed can now be reversed after each config function. See CTH Execution Order.
- OTP-18761
-
- Related Id(s):
The default CSS will now include a basic dark mode handling if it is preferred by the browser.
- OTP-18781
-
- Related Id(s):
-callbackattributes have been added toct_suiteandct_hooks. - OTP-18875
-
- Related Id(s):
The built-in cth_log_redirect hook can now be configured to replace default logger reports in terminal with HTML logs.
- OTP-18881
-
- Related Id(s):
Error handling for the
ct_property_testframework has been enhanced. - OTP-18892
-
- Related Id(s):
Enhance test case documentation, making it clear how a test case can be failed.
- OTP-18898
-
- Related Id(s):
The failing line in the test source code is now colored to make it easier to find on the screen.
- OTP-18913
-
Function specifications and types have been added to all public API functions.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18981
-
The suite execution elapsed time is now included in the index page.
Full runtime dependencies of common_test-1.27
compiler-6.0, crypto-4.5, debugger-4.1, erts-7.0, ftp-1.0, inets-6.0, kernel-8.4, observer-2.1, runtime_tools-1.8.16, sasl-2.5, snmp-5.1.2, ssh-4.0, stdlib-4.0, syntax_tools-1.7, tools-3.2, xmerl-1.3.8
compiler-8.5 #
- OTP-18703
-
Generators for binary comprehensions could be evaluated before it was known that they would be needed. That could result in a binary comprehensions failing if a generator that should not be evaluated until later failed.
As an example, consider this module:
-module(t). -export([f/0]). f() -> <<0 || _ <- [], _ <- ok, false>>.In Erlang/OTP 26 it would fail like so:
1> t:f(). ** exception error: bad generator ok in function t:f/0 (t.erl, line 6)In Erlang/OTP 27 it returns an empty binary:
1> t:f(). <<>> - OTP-18784
-
- POTENTIAL INCOMPATIBILITY
The documentation for the preprocessor now mentions that
defined(Name)can be called in the condition for an-ifor-elifdirective to test whetherNameis the name of a defined macro. (This feature was implemented in OTP 21.)If a function call in an
-ifor-elifwith a name that is not the name of a guard BIF, there would not be a compilation error, but would instead cause the lines following the directive to be skipped. This has now been changed to be a compilation error. - OTP-18648
-
- HIGHLIGHT
The compiler now emits nicer error message for function head mismatches. For example, given:
a() -> ok; a(_) -> error.Erlang/OTP 26 and earlier would emit a diagnostic similar to:
t.erl:6:1: head mismatch % 6| a(_) -> error. % | ^while in Erlang/OTP 27 the diagnostic is similar to:
t.erl:6:1: head mismatch: function a with arities 0 and 1 is regarded as two distinct functions. Is the number of arguments incorrect or is the semicolon in a/0 unwanted? % 6| a(_) -> error. % | ^ - OTP-18673
-
- Related Id(s):
-
ERIERL-964, PR-7474
The compiler now optimizes creation of binaries that are known to be constant.
Consider this example:
bin() -> C = char(), <<C>>. char() -> $*.Essentially, the compiler rewrites the example to the slightly more efficient:
bin() -> _ = char(), <<$*>>. char() -> $*. - OTP-18680
-
- HIGHLIGHT
The compiler will now merge consecutive updates of the same record.
As an example, the body of the following function will be combined into a single tuple creation instruction:
-record(r, {a,b,c,d}). update(Value) -> R0 = #r{}, R1 = R0#r{a=Value}, R2 = R1#r{b=2}, R2#r{c=3}. - OTP-18714
-
Improved the performance of the alias analysis pass.
- OTP-18801
-
- Related Id(s):
-specattributes are now used for documentation. - OTP-18856
-
- HIGHLIGHT
Native coverage support has been implemented in the JIT. It will automatically be used by the
covertool to reduce the execution overhead when running cover-compiled code.There are also new APIs to support native coverage without using the
covertool.To instrument code for native coverage it must be compiled with the
line_coverageoption.To enable native coverage in the runtime system, start it like so:
$ erl +JPcover trueThere are also the following new functions for supporting native coverage:
code:coverage_support/0code:get_coverage/2code:reset_coverage/1code:get_coverage_mode/0code:get_coverage_mode/1code:set_coverage_mode/1
- OTP-18916
-
- HIGHLIGHT
EEP-59 - Documentation Attributes has been implemented.
Documentation attributes can be used to document functions, types, callbacks, and modules. The keyword
-moduledoc "Documentation here".is used to document modules, while-doc "Documentation here".can be used on top of functions, types, and callbacks to document them, respectively.- Types, callbacks, and function documentation can be set to
hiddeneither via-doc falseor-doc hidden. When documentation attributes mark a type as hidden, they will not be part of the documentation. - The documentation from
moduledocanddocgets added by default to the binary beam file, following the format of EEP-48. - Using the compiler flag
warn_missing_docwill raise a warning when-docattributes are missing in exported functions, types, and callbacks. - Using the compiler flag
warn_missing_spec_documentedwill raise a warning when spec attributes are missing in documented functions, types, and callbacks. moduledocs anddocs may refer to external files to be embedded, such as-doc {file, "README.md"}., which refers to the fileREADME.mdfound in the current working directory.- The compiler warns about exported functions whose specs refer to hidden types. Thus, there will be warnings when a hidden type (meaning, the type is not part of the documentation) gets used in an exported function.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18968
-
- POTENTIAL INCOMPATIBILITY
The order in which the compiler looks up options has changed.
When there is a conflict in the compiler options given in the
-compile()attribute and options given to the compiler, the options given in the-compile()attribute overrides the option given to the compiler, which in turn overrides options given in theERL_COMPILER_OPTIONSenvironment variable.Example:
If
some_module.erlhas the following attribute:-compile([nowarn_missing_spec]).and the compiler is invoked like so:
% erlc +warn_missing_spec some_module.erlno warnings will be issued for functions that do not have any specs.
- OTP-18972
-
- HIGHLIGHT
Safe destructive update of tuples has been implemented in the compiler and runtime system. This allows the VM to update tuples in-place when it is safe to do so, thus improving performance by doing less copying but also by producing less garbage.
Example:
-record(rec, {a,b,c}). update(#rec{a=needs_update,b=N}=R0) -> R = R0#rec{a=up_to_date}, if N < 0 -> R#rec{c=negative}; N == 0 -> R#rec{c=zero}; N > 0 -> R#rec{c=positive} end.The record updates in each of the three clauses of the
ifcan safely be done in-place, because variableRis not used again. - OTP-18987
-
Improved the match context reuse optimization slightly, allowing match contexts to be passed as-is to
bit_size/1andbyte_size/1. - OTP-19010
-
- Related Id(s):
m:erl_lint(and by extension thecompiler) will now warn for code using deprecated callbacks.The only callback currenly deprecated is
format_status/2ingen_server,gen_eventandgen_statem.You can use
nowarn_deprecated_callbackto silence the warning.
Full runtime dependencies of compiler-8.5
crypto-5.1, erts-13.0, kernel-8.4, stdlib-6.0
crypto-5.5 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18973
-
Removed functions
crypto_dyn_iv_init/3andcrypto_dyn_iv_update/3which were marked as deprecated since OTP 25. - OTP-18975
-
- Related Id(s):
Add support for sm3 hash and hmac.
- OTP-18978
-
- Related Id(s):
OPENSSL_thread_stopis called whencryptois purged to not leak thread specific data. - OTP-19005
-
- Related Id(s):
Add SM4 block cipher implemented according to GB/T 32907-2016.
- OTP-19016
-
- POTENTIAL INCOMPATIBILITY
The existing function
ssl:key_exporter_materials/4is now documented and supported. - OTP-19075
-
Due to another attack on PKCS #1 v1.5 padding, known as the Marvin attack, about which we were alerted by Hubert Kario from Red Hat. You can find more details about the attack at https://people.redhat.com/~hkario/marvin/ Functions that may be vulnerable are now deprecated.
Note that you might mitigate the problem by using appropriate versions of OpenSSL together with our software, but we recommend not using them at all.
Also avoid using TLS versions prior to TLS-1.2 (not supported by default) and do not enable RSA-key exchange cipher suites (not supported by default).
Full runtime dependencies of crypto-5.5
erts-9.0, kernel-5.3, stdlib-3.9
debugger-5.4 #
- OTP-18831
-
- Related Id(s):
The dependencies for this application are now listed in the app file.
- OTP-18819
-
- Related Id(s):
Type specs have been added to all API functions.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19074
-
- Related Id(s):
The Debugger now use a trace session for its internal use of tracing to avoid interfering with the user’s use of tracing.
Full runtime dependencies of debugger-5.4
compiler-8.0, erts-15.0, kernel-10.0, stdlib-3.15, wx-2.0
diameter-2.4 #
- OTP-18783
-
- Related Id(s):
-callbackattributes have been added todiameter_appanddiameter_transport. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19090
-
- Related Id(s):
Pick peer can now also handle request of type
#diameter_packet{}.
Full runtime dependencies of diameter-2.4
erts-10.0, kernel-3.2, ssl-9.0, stdlib-5.0
edoc-1.3 #
- OTP-18945
-
- Related Id(s):
EEP 48 doc chunks now properly include links within
{@type }macros. - OTP-18946
-
- Related Id(s):
@hiddennow meanshiddenin EEP 48 doc chunks instead ofnone. - OTP-18947
-
- Related Id(s):
There is a new
edoc_html_to_markdownmodule that can be used to convert EEP-48application/html+erlangto Markdown. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19052
-
- Related Id(s):
Added module
edoc_doclet_markdownthat can be used to convert EDoc style documentation to Markdown documentation attributes.
Full runtime dependencies of edoc-1.3
erts-11.0, inets-5.10, kernel-7.0, stdlib-4.0, syntax_tools-2.0, xmerl-1.3.7
eldap-1.2.13 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of eldap-1.2.13
asn1-3.0, erts-6.0, kernel-3.0, ssl-5.3.4, stdlib-3.4
erl_interface-5.5.2 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-16607
-
- Related Id(s):
-
OTP-16608
The
eiAPI for decoding/encoding terms is not fully 64-bit compatible since terms that have a representation on the external term format larger than 2 GB cannot be handled.
erts-15.0 #
- OTP-18766
-
- Related Id(s):
Bugs in how
erl -extrainteracts with passing flags via ERL_*FLAGS or-args_filehave been fixed. - OTP-18918
-
- Related Id(s):
Fixed a bug that prevented the emulator from building on recent versions of Yocto Linux.
- OTP-18928
-
- Related Id(s):
Fixed spectre mitigation configure test to work with GCC patches to always add
-fcf-protection=full. - OTP-19063
-
- Related Id(s):
-
OTP-18835
A call to
socket:[recv|recvfrom|recvmsg]/*with Timeout = 0 on Windows could cause a (case clause) crash if data is immediately available. - OTP-19077
-
- Related Id(s):
Fix bug on Windows where
exit_statuswould not be sent when a port exits after the stdin/stdout handles have been closed. - OTP-18568
-
- Related Id(s):
Refactored how the JIT handles POSIX signals and how they affect thread stacks, allowing us to use the native stack register for Erlang stacks on more platforms.
Notably, containers built on 64-bit x86 Alpine Linux images will now perform much better in sequential code. As an example, running
dialyzerover the OTP code base finishes about 15% quicker. - OTP-18577
-
- Related Id(s):
The
instrumentmodule can now track allocations on a per-process or per-port basis. - OTP-18594
-
- POTENTIAL INCOMPATIBILITY
The
pidfield returned fromerlang:fun_info/1,2is now always the pid for theinitprocess of the local node, not the pid for the actual process that created the fun. - OTP-18639
-
- POTENTIAL INCOMPATIBILITY
By default, escripts will now be compiled instead of interpreted. That means that the
compilerapplication must be installed. - OTP-18642
-
A binary returned from the
socketreceive functions is no longer created as a sub binary of an often large receive buffer binary (socket option{otp,rcvbuf}). This avoids space waste, trusting the allocators to implement reallocation efficiently. - OTP-18699
-
- Related Id(s):
The default process limit has been raised to
1048576processes. - OTP-18709
-
- Related Id(s):
The
erlang:system_monitor/2functionality is now able to monitor long message queues in the system. - OTP-18744
-
- HIGHLIGHT
The
erlcommand now supports the-Sflag, which is similar to the-runflag, except that it will pass all arguments up to end of the command line to the called function. (The-runflag will not pass arguments beginning with a hyphen.) Another difference is that-Swill always call a function with one argument, passing an empty list if no arguments were given. - OTP-18774
-
- Related Id(s):
When implementing an alternative carrier for the Erlang distribution, a separate input handler process may now be registered, using
erlang:dist_ctrl_input_handler/2, also in the case when the distribution controller is a port. - OTP-18779
-
- Related Id(s):
The call stack trace has now been added to the error reported by
erlang:process_flag/2whenmax_heap_sizelimit has been exceeded. - OTP-18794
-
- Related Id(s):
-callbackattributes have been added toerl_tracer. - OTP-18835
-
For
inet_backend = socket, setting theactivesocket option alone, toonce,trueorNhas been optimized, as well as the corresponding data delivery. - OTP-18845
-
New functions
socket:sendv/*for sending I/O vectors have been added. - OTP-18849
-
- Related Id(s):
Socket options that take string now also accept binaries.
- OTP-18856
-
- HIGHLIGHT
Native coverage support has been implemented in the JIT. It will automatically be used by the
covertool to reduce the execution overhead when running cover-compiled code.There are also new APIs to support native coverage without using the
covertool.To instrument code for native coverage it must be compiled with the
line_coverageoption.To enable native coverage in the runtime system, start it like so:
$ erl +JPcover trueThere are also the following new functions for supporting native coverage:
code:coverage_support/0code:get_coverage/2code:reset_coverage/1code:get_coverage_mode/0code:get_coverage_mode/1code:set_coverage_mode/1
- OTP-18894
-
- Related Id(s):
Changed the default value of the command line flag
-code_path_choicetostrict.Note that for application systems using archives, it is necessary to add the
code_path_choice relaxedto the command line that invokeserl. - OTP-18929
-
- Related Id(s):
Added module loading to
erl -init_debugprintouts. - OTP-18938
-
When the runtime system halts, it performs various flush operations before terminating. By default there is no limit on how much time the flush operations are allowed to take. A new halt flush timeout functionality has been introduced which can be used for limiting the amount of time that the flushing operations are allowed to take. For more information see the documentation of the
flush_timeoutoption of theerlang:halt/2BIF and the documentation of theerl+zhft <Timeout>command line flag. - OTP-18941
-
- Related Id(s):
Optimized code loading by moving certain operations from the code server to the caller.
- OTP-18942
-
Updated asmjit to version a465fe71ab3d0e224b2b4bd0fac69ae68ab9239d
- OTP-18950
-
The deprecated functions in
zlibhave been removed. That includesinflateChunk/{1,2},getBufSize/1,setBufSize/2, the CRC32 functions, and the Adler checksum functions. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18972
-
- HIGHLIGHT
Safe destructive update of tuples has been implemented in the compiler and runtime system. This allows the VM to update tuples in-place when it is safe to do so, thus improving performance by doing less copying but also by producing less garbage.
Example:
-record(rec, {a,b,c}). update(#rec{a=needs_update,b=N}=R0) -> R = R0#rec{a=up_to_date}, if N < 0 -> R#rec{c=negative}; N == 0 -> R#rec{c=zero}; N > 0 -> R#rec{c=positive} end.The record updates in each of the three clauses of the
ifcan safely be done in-place, because variableRis not used again. - OTP-18976
-
- Related Id(s):
The obsolete and undocumented support for opening a port to an external resource by passing an atom (or a string) as first argument to
open_port(), implemented by the vanilla driver, has been removed. This feature has been scheduled for removal in OTP 27 since the release of OTP 26. - OTP-18977
-
- Related Id(s):
An optional NIF callback
ERL_NIF_OPT_ON_UNLOAD_THREADto be called by all scheduler threads when a NIF library is unloaded. Used for releasing thread specific data. Can be set with functionenif_set_option. - OTP-18980
-
There is a new module
tracein Kernel providing the same trace functionality aserlang:trace/3anderlang:trace_pattern/3, but with the addition of dynamic isolated trace sessions. - OTP-18984
-
- Related Id(s):
Added the
+MMlp on|offemulator option to let themsegallocator use “large pages” (sometimes known as “huge pages” or “super pages”). This currently only affects super-carrier allocations, but may be extended in the future. - OTP-19004
-
- Related Id(s):
-
OTP-18835
inet_backend = sockethas been optimized and reworked to be more compatible with the originalinet_backend = inet. - OTP-19054
-
The
socketdocumentation has been reworked, and due to that a few details were fixed:socket:is_supported/1now returnstruefor example forprotocolsthat is a “category”, not an item.socket:cancel_monitor/1no longer badargs for a monitor that was set by another process, instead it returnsfalseas for other unknownreference()s.
Full runtime dependencies of erts-15.0
kernel-9.0, sasl-3.3, stdlib-4.1
et-1.7.1 #
- OTP-18831
-
- Related Id(s):
The dependencies for this application are now listed in the app file.
- OTP-18860
-
Dialyzer warnings due to type specs added in
dbghave been eliminated. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of et-1.7.1
erts-9.0, kernel-5.3, runtime_tools-1.10, stdlib-3.4, wx-1.2
eunit-2.9.1 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of eunit-2.9.1
erts-9.0, kernel-5.3, stdlib-3.4
inets-9.2 #
- OTP-18641
-
- POTENTIAL INCOMPATIBILITY
Introduced a default value for httpd_server name configuration to improve ease of use.
- OTP-18727
-
- Related Id(s):
The
httpdmodule has been extended with an API for simple serving directory content over HTTP. With this change, the current working directory can be served like this:erl -S httpdAn arbitrary directory can be served like this:
erl -S httpd serve path/to/dir - OTP-18786
-
- Related Id(s):
Added
-callbackattributes tohttpd,mod_esi, andmod_security. - OTP-18809
-
Inets now uses a relative redirect with an absolute path to prevent whoever is running Inets from having to configure the
ServerNameto match the network-reachable host name of the server. - OTP-18927
-
- Related Id(s):
inetsprocesses now useproc_lib:set_label/1to improve observeability. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19022
-
The implementations of
http_uri:encode/1andhttp_uri:decode/1are now replaced with their equivalent, but bug free versions from moduleuri_string, namelyuri_string:quote/1anduri_string:unquote/1. - OTP-19033
-
With this change, the API specs are updated.
Full runtime dependencies of inets-9.2
erts-14.0, kernel-9.0, mnesia-4.12, public_key-1.13, runtime_tools-1.8.14, ssl-9.0, stdlib-5.0, stdlib-6.0
jinterface-1.14.1 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
kernel-10.0 #
- OTP-18590
-
- Related Id(s):
Fixed a crash when calling
file:delete/2with an empty option list. - OTP-18878
-
- Related Id(s):
-
GH-7718, OTP-17734
New functions have been added to the undocumented module
inet_dnsthat take a flag to specify if encode/decode is for mDNS. This affects how CLASS values in the private range, with the top bit set, are handled. - OTP-18904
-
- Related Id(s):
The error information for
erlang:phash/2has been corrected. - OTP-18930
-
get_untilrequests using the I/O protocol now correctly return a binary or list wheneofis the last item returned by the callback. - OTP-18954
-
Calling
logger:add_handlers/1with config option now works. - OTP-18959
-
The
code:del_path/1function now also works on paths added through-pa,-pz,-pathand the boot script. - OTP-19063
-
- Related Id(s):
-
OTP-18835
A call to
socket:[recv|recvfrom|recvmsg]/*with Timeout = 0 on Windows could cause a (case clause) crash if data is immediately available. - OTP-19087
-
- Related Id(s):
Improve heuristic for when a characters is wide in the shell for systems with old libc versions.
- OTP-19088
-
Fix reading a line when reading from
io:user/0to not consider\rwithout\nto be a new line whenerlis started with-noshell. - OTP-18589
-
- Related Id(s):
Added
file:read_file/2with arawoption for reading files without going through the file server. - OTP-18713
-
The undocumented Erlang DNS resolver library (
inet_dnsandinet_res) has been augmented to handle IXFR, NOTIFY, UPDATE and TSIG records. With this some bug fixes and code cleanup has been done, and the resolver used in the test suite has been changed to Knot DNS. See the source code.Kudos to Alexander Clouter that did almost all the work!
- OTP-18778
-
- Related Id(s):
The
ebindirectories for escripts are now cached. - OTP-18795
-
- Related Id(s):
-callbackattributes haven been added toapplication,logger_handler, andlogger_formatter. - OTP-18807
-
- Related Id(s):
-
ERIERL-985, PR-7732
Progress reports from before logger is started are now logged when log level is set to debug.
- OTP-18816
-
- Related Id(s):
The
code:where_is_file/2andcode:which/1functions now check for existence of the file directly instead of listing the content of each directory in the code path. - OTP-18820
-
- Related Id(s):
Type specs has been added to the
logger:Level/1,2,3functions. - OTP-18835
-
For
inet_backend = socket, setting theactivesocket option alone, toonce,trueorNhas been optimized, as well as the corresponding data delivery. - OTP-18845
-
New functions
socket:sendv/*for sending I/O vectors have been added. - OTP-18846
-
- Related Id(s):
The shell now pages long output from the documentation help command (
h(Module)), auto completions and the search command. - OTP-18856
-
- HIGHLIGHT
Native coverage support has been implemented in the JIT. It will automatically be used by the
covertool to reduce the execution overhead when running cover-compiled code.There are also new APIs to support native coverage without using the
covertool.To instrument code for native coverage it must be compiled with the
line_coverageoption.To enable native coverage in the runtime system, start it like so:
$ erl +JPcover trueThere are also the following new functions for supporting native coverage:
code:coverage_support/0code:get_coverage/2code:reset_coverage/1code:get_coverage_mode/0code:get_coverage_mode/1code:set_coverage_mode/1
- OTP-18941
-
- Related Id(s):
Optimized code loading by moving certain operations from the code server to the caller.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18963
-
- Related Id(s):
Application startup has been optimized by removing an intermediary process.
- OTP-18966
-
- POTENTIAL INCOMPATIBILITY
The existing experimental support for archive files will be changed in a future release. The support for having an archive in an escript will remain, but the support for using archives in a release will either become more limited or completely removed.
As of Erlang/OTP 27, the function
code:lib_dir/2, the-code_path_choiceflag, and usingerl_prim_loaderfor reading members of an archive are deprecated.To remain compatible with future version of Erlang/OTP
escriptscripts that need to retrieve data files from its archive should useescript:extract/2instead oferl_prim_loaderandcode:lib_dir/2. - OTP-18967
-
- Related Id(s):
The undocumented and deprecated
file:pid2namefunction has been removed. - OTP-18980
-
There is a new module
tracein Kernel providing the same trace functionality aserlang:trace/3anderlang:trace_pattern/3, but with the addition of dynamic isolated trace sessions. - OTP-18989
-
- Related Id(s):
Error logging has been improved when the
io:standard_io/0reader and/or writer terminates with an error. - OTP-19004
-
- Related Id(s):
-
OTP-18835
inet_backend = sockethas been optimized and reworked to be more compatible with the originalinet_backend = inet. - OTP-19042
-
Add an simple example (echo server) )to the socket users guide.
- OTP-19053
-
- Related Id(s):
inet:i/0,1,2has been improved to allow port numbers to be shown explicitly. - OTP-19054
-
The
socketdocumentation has been reworked, and due to that a few details were fixed:socket:is_supported/1now returnstruefor example forprotocolsthat is a “category”, not an item.socket:cancel_monitor/1no longer badargs for a monitor that was set by another process, instead it returnsfalseas for other unknownreference()s.
- OTP-19089
-
- Related Id(s):
Add
stdin,stdoutandstderrkeys toio:getopts/1onio:standard_io/0to indicate if the respective I/O device is backed by a terminal.
Full runtime dependencies of kernel-10.0
crypto-5.0, erts-15.0, sasl-3.0, stdlib-6.0
megaco-4.6 #
- OTP-18806
-
- Related Id(s):
-callbackattributes have been added tomegaco_transport. - OTP-18920
-
- Related Id(s):
-
BL-322
Updated types and specs for all API modules.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of megaco-4.6
asn1-3.0, debugger-4.0, erts-12.0, et-1.5, kernel-8.0, runtime_tools-1.8.14, stdlib-2.5
mnesia-4.23.2 #
- OTP-18994
-
The
mnesia_registrymodule have been deprecated. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of mnesia-4.23.2
erts-9.0, kernel-5.3, stdlib-5.0
observer-2.16 #
- OTP-18831
-
- Related Id(s):
The dependencies for this application are now listed in the app file.
- OTP-18789
-
The new function
proc_lib:set_label/1can be used to add a descriptive term to any process that does not have a registered name. The name will be shown by tools such as\c:i/0,observer, and it will be included in crash reports produced by processes usinggen_server,gen_statem,gen_event, andgen_fsm.The label for a process can be retrieved by calling
proc_lib:get_label/1.Note that those functions work on any process, not only processes that use
proc_lib.Example:
1> self(). <0.90.0> 2> proc_lib:set_label(my_label). ok 3> i(). . . . <0.90.0> erlang:apply/2 2586 75011 0 my_label c:pinfo/2 51 4> proc_lib:get_label(self()). my_label - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19082
-
- Related Id(s):
m:etophas been updated to usedbg:session/2in order to not interfere with any other tracing.
Full runtime dependencies of observer-2.16
erts-15.0, et-1.5, kernel-10.0, runtime_tools-2.1, stdlib-5.0, wx-2.3
odbc-2.14.3 #
- OTP-19030
-
The order of libs in the Makefile has been changed to avoid finding the system’s
libeiinstead of Erlang’slibei. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of odbc-2.14.3
erts-6.0, kernel-3.0, stdlib-2.0
os_mon-2.10 #
- OTP-18913
-
Function specifications and types have been added to all public API functions.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of os_mon-2.10
erts-14.0, kernel-9.0, sasl-4.2.1, stdlib-5.0
parsetools-2.6 #
- OTP-18796
-
- Related Id(s):
The
leexdocumentation has been updated to use specs for documenting the generated interface. - OTP-18912
-
- Related Id(s):
yecc now wraps the
-moduleattribute with-fileto indicate the.yrlsource file. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of parsetools-2.6
erts-6.0, kernel-3.0, stdlib-3.4
public_key-1.16 #
- OTP-18606
-
- HIGHLIGHT
The
sslclient can negotiate and handle certificate status request (OCSP stapling support on the client side).Thanks to voltone for interop testing and related discussions.
- OTP-18609
-
The exception reason when
public_key:cacerts_get/0failed has been improved. - OTP-18876
-
Key customization support has been extended to allow flexibility for implementers of for instance hardware security modules (HSM) or trusted platform modules (TPM).
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19016
-
- POTENTIAL INCOMPATIBILITY
The existing function
ssl:key_exporter_materials/4is now documented and supported. - OTP-19075
-
Due to another attack on PKCS #1 v1.5 padding, known as the Marvin attack, about which we were alerted by Hubert Kario from Red Hat. You can find more details about the attack at https://people.redhat.com/~hkario/marvin/ Functions that may be vulnerable are now deprecated.
Note that you might mitigate the problem by using appropriate versions of OpenSSL together with our software, but we recommend not using them at all.
Also avoid using TLS versions prior to TLS-1.2 (not supported by default) and do not enable RSA-key exchange cipher suites (not supported by default).
Full runtime dependencies of public_key-1.16
asn1-3.0, crypto-4.6, erts-6.0, kernel-3.0, stdlib-3.5
reltool-1.0.1 #
- OTP-18831
-
- Related Id(s):
The dependencies for this application are now listed in the app file.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of reltool-1.0.1
erts-15.0, kernel-9.0, sasl-4.2.1, stdlib-5.0, tools-2.6.14, wx-2.3
runtime_tools-2.1 #
- OTP-18577
-
- Related Id(s):
The
instrumentmodule can now track allocations on a per-process or per-port basis. - OTP-18789
-
The new function
proc_lib:set_label/1can be used to add a descriptive term to any process that does not have a registered name. The name will be shown by tools such as\c:i/0,observer, and it will be included in crash reports produced by processes usinggen_server,gen_statem,gen_event, andgen_fsm.The label for a process can be retrieved by calling
proc_lib:get_label/1.Note that those functions work on any process, not only processes that use
proc_lib.Example:
1> self(). <0.90.0> 2> proc_lib:set_label(my_label). ok 3> i(). . . . <0.90.0> erlang:apply/2 2586 75011 0 my_label c:pinfo/2 51 4> proc_lib:get_label(self()). my_label - OTP-18859
-
- Related Id(s):
Type specs had been added to all
dbgfunctions. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19081
-
- Related Id(s):
m:dbghave been updated to use trace sessions.dbg:session_create/1,dbg:session/2, anddbg:session_destroy/1have been added to work sessions. See the documentation for details.
Full runtime dependencies of runtime_tools-2.1
erts-15.0, kernel-10.0, mnesia-4.12, stdlib-6.0
sasl-4.2.2 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of sasl-4.2.2
erts-15.0, kernel-6.0, stdlib-4.0, tools-2.6.14
snmp-5.16 #
- OTP-18785
-
- Related Id(s):
-callbackattributes have been added to modulessnmpa_network_interface_filter,snmpa_notification_filter,snmpm_network_interface_filter,snmpm_user, andsnmpa_notification_delivery_info_receiver.New
-typeattributes have also been added to modulessnmp,snmpa,snmpm, andsnmpa_confto support the previously mentioned callbacks. - OTP-18934
-
- Related Id(s):
-
BL-312
Updated types and specs for all API modules.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of snmp-5.16
crypto-4.6, erts-12.0, kernel-8.0, mnesia-4.12, runtime_tools-1.8.14, stdlib-5.0
ssh-5.2 #
- OTP-19017
-
- Related Id(s):
SSH processes are now assigned labels for troubleshooting purposes.
- OTP-19057
-
With this change, ssh client will automatically adjust transfer window size for commands executed remotely over SSH.
- OTP-18846
-
- Related Id(s):
The shell now pages long output from the documentation help command (
h(Module)), auto completions and the search command. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18961
-
Updated types and specs for all API modules.
Full runtime dependencies of ssh-5.2
crypto-5.0, erts-14.0, kernel-9.0, public_key-1.6.1, runtime_tools-1.15.1, stdlib-5.0, stdlib-6.0
ssl-11.2 #
- OTP-18887
-
Starting a TLS server without sufficient credentials (certificate or anonymous cipher) would work, but it was impossible to connect to it.
This has been corrected to return an error instead of starting the server.
- OTP-18969
-
ASN.1 decoding errors are handled in more places to ensure that errors are returned instead of cause a crash.
- OTP-18992
-
Improved error checking on the API functions.
- OTP-18606
-
- HIGHLIGHT
The
sslclient can negotiate and handle certificate status request (OCSP stapling support on the client side).Thanks to voltone for interop testing and related discussions.
- OTP-18665
-
- Related Id(s):
Memory consumption has been reduced and performance increased by refactoring internal data structures and their usage.
- OTP-18788
-
- Related Id(s):
Added
ssl_crl_cache_api:lookup/2as an optional-callbackattribute. - OTP-18876
-
Key customization support has been extended to allow flexibility for implementers of for instance hardware security modules (HSM) or trusted platform modules (TPM).
- OTP-18879
-
The
proc_lib:set_label/1function is now used to increase observability ofsslprocesses. - OTP-18884
-
- Related Id(s):
Brainpool elliptic curves are now supported in TLS-1.3.
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19025
-
- HIGHLIGHT, POTENTIAL INCOMPATIBILITY
For security reasons, the CBC ciphers are now longer included in the list of default ciphers for TLS-1.2.
- OTP-19027
-
- Related Id(s):
There is a new
cert_policy_optsoption to configure certificate policy options for the certificate path validation.
Full runtime dependencies of ssl-11.2
crypto-5.0, erts-15.0, inets-5.10.7, kernel-9.0, public_key-1.15, runtime_tools-1.15.1, stdlib-6.0
stdlib-6.0 #
- OTP-18684
-
- Related Id(s):
The specs in module
binaryhas been updated to reflect what is allowed by the documentation. - OTP-18743
-
Several functions in the
binarymodule would accept arguments of the wrong type under certain circumstances. In this release, they now raise an exception when incorrect types are given.The following functions would accept an invalid pattern if the subject binary was empty or if the
{scope,{0,0}}option was given:binary:match/2,3,binary:matches/2,3,binary:replace/3,4, andbinary:split/2,3The call
binary:copy(<<1:1>>, 0)would return an empty binary instead of raising an exception. Similarly, calls tobinary:part/2,3attempting to extract 0 bytes at position 0 of a bitstring would return an empty binary instead of raising an exception. - OTP-18784
-
- POTENTIAL INCOMPATIBILITY
The documentation for the preprocessor now mentions that
defined(Name)can be called in the condition for an-ifor-elifdirective to test whetherNameis the name of a defined macro. (This feature was implemented in OTP 21.)If a function call in an
-ifor-elifwith a name that is not the name of a guard BIF, there would not be a compilation error, but would instead cause the lines following the directive to be skipped. This has now been changed to be a compilation error. - OTP-18930
-
get_untilrequests using the I/O protocol now correctly return a binary or list wheneofis the last item returned by the callback. - OTP-19029
-
- POTENTIAL INCOMPATIBILITY
The error handling the
simple_one_for_onesupervisor has been enhanced. A transient child returningignorewill no longer cause a crash.Also, automatic shutdown has been disabled because it does not make sense for this supervisor type. That is was allowed is considered a bug. Therefore, we don’t consider this an incompatible change.
- OTP-19073
-
Fix shell expansion to not crash when expanding a map with non-atom keys and to not list zero arity functions when an argument has been given.
- OTP-18622
-
- HIGHLIGHT
The functions
is_equal/2,map/2, andfiltermap/2have been added to the modulessets,ordsets, andgb_sets. - OTP-18648
-
- HIGHLIGHT
The compiler now emits nicer error message for function head mismatches. For example, given:
a() -> ok; a(_) -> error.Erlang/OTP 26 and earlier would emit a diagnostic similar to:
t.erl:6:1: head mismatch % 6| a(_) -> error. % | ^while in Erlang/OTP 27 the diagnostic is similar to:
t.erl:6:1: head mismatch: function a with arities 0 and 1 is regarded as two distinct functions. Is the number of arguments incorrect or is the semicolon in a/0 unwanted? % 6| a(_) -> error. % | ^ - OTP-18668
-
zip:create/2,3will now tolerate POSIX timestamps in the providedfile_inforecords. - OTP-18671
-
- Related Id(s):
The callback function
gen_statem:handle_event/4has been cached in thegen_statemengine to optimize callback call speed. - OTP-18716
-
- Related Id(s):
The type
beam_lib:beam/0is now exported. - OTP-18741
-
- Related Id(s):
The documentation for the
binarymodule has been improved. - OTP-18742
-
- Related Id(s):
binary:replace/3,4now supports using a fun for supplying the replacement binary. - OTP-18750
-
- HIGHLIGHT, POTENTIAL INCOMPATIBILITY
Triple-Quoted Strings has been implemented as per EEP 64. See String in the Reference Manual.
Example:
1> """ a b c """. "a\nb\nc"Adjacent string literals without intervening white space is now a syntax error, to avoid possible confusion with triple-quoted strings. For example:
1> "abc""xyz". "xyz". * 1:6: adjacent string literals without intervening white space - OTP-18789
-
The new function
proc_lib:set_label/1can be used to add a descriptive term to any process that does not have a registered name. The name will be shown by tools such as\c:i/0,observer, and it will be included in crash reports produced by processes usinggen_server,gen_statem,gen_event, andgen_fsm.The label for a process can be retrieved by calling
proc_lib:get_label/1.Note that those functions work on any process, not only processes that use
proc_lib.Example:
1> self(). <0.90.0> 2> proc_lib:set_label(my_label). ok 3> i(). . . . <0.90.0> erlang:apply/2 2586 75011 0 my_label c:pinfo/2 51 4> proc_lib:get_label(self()). my_label - OTP-18793
-
- Related Id(s):
-callbackattributes has been added to modulessysanderl_error. - OTP-18808
-
- HIGHLIGHT
Several new functions that accept funs have been added to module
timer.Functions
apply_after/2,apply_interval/2, andapply_repeatedly/2accept a nullary fun as the second argument, while functionsapply_after/3,apply_interval/3, andapply_repeatedly/3accept an n-ary fun as the second and a list of n arguments for the fun as the third argument. - OTP-18825
-
- HIGHLIGHT
Sigils on string literals have been implemented as per EEP 66, that is: binary and string sigils in verbatim and escape characters variants, as well as a default (vanilla) Sigil. All for ordinary strings and for triple-quoted strings (EEP 64). See Sigils in the Reference Manual.
Examples:
1> ~"Björn". <<"Björn"/utf8>> 2> ~b"Björn". <<"Björn"/utf8>> 3> ~S"\s*(\w+)". "\\s*(\\w+)" 4> ~B"\s*(\w+)". <<"\\s*(\\w+)">> - OTP-18834
-
Functions
shell:default_multiline_prompt/1,shell:inverted_space_prompt/1, andshell:prompt_width/1have been exported to help with custom prompt implementations. - OTP-18846
-
- Related Id(s):
The shell now pages long output from the documentation help command (
h(Module)), auto completions and the search command. - OTP-18847
-
- Related Id(s):
The
M-hhotkey (Alt/Option-h) now outputs help for the module or function directly before the cursor. - OTP-18848
-
- Related Id(s):
Added support for adding a custom code formatter that formats your multi-line shell commands in your preferred formatting on submission. See
shell:format_shell_func/andshell:erl_pp_format_func/1. - OTP-18852
-
- Related Id(s):
Added shell functions for viewing, forgetting and saving locally defined functions, types and records.
- OTP-18865
-
- Related Id(s):
Added
string:jaro_similarity/2, which can be used to calculate the similarity between two strings. - OTP-18870
-
- Related Id(s):
The new function
ets:update_element/4is similar toets:update_element/3, but takes a default tuple as the fourth argument, which will be inserted if no previous record with that key exists. - OTP-18874
-
- Related Id(s):
Added functions to retrieve the next higher or lower key/element from
gb_treesandgb_sets, as well as returning iterators that start at given keys/elements. - OTP-18908
-
- Related Id(s):
When the shell built-in function
c/1,2is used to re-compile a module, the current working directory of the original compilation is now added to the include path. - OTP-18914
-
- Related Id(s):
The
timermodule now uses a private table for its internal state, slightly improving its performance. - OTP-18916
-
- HIGHLIGHT
EEP-59 - Documentation Attributes has been implemented.
Documentation attributes can be used to document functions, types, callbacks, and modules. The keyword
-moduledoc "Documentation here".is used to document modules, while-doc "Documentation here".can be used on top of functions, types, and callbacks to document them, respectively.- Types, callbacks, and function documentation can be set to
hiddeneither via-doc falseor-doc hidden. When documentation attributes mark a type as hidden, they will not be part of the documentation. - The documentation from
moduledocanddocgets added by default to the binary beam file, following the format of EEP-48. - Using the compiler flag
warn_missing_docwill raise a warning when-docattributes are missing in exported functions, types, and callbacks. - Using the compiler flag
warn_missing_spec_documentedwill raise a warning when spec attributes are missing in documented functions, types, and callbacks. moduledocs anddocs may refer to external files to be embedded, such as-doc {file, "README.md"}., which refers to the fileREADME.mdfound in the current working directory.- The compiler warns about exported functions whose specs refer to hidden types. Thus, there will be warnings when a hidden type (meaning, the type is not part of the documentation) gets used in an exported function.
- OTP-18923
-
- HIGHLIGHT
New
etsfunctionsets:first_lookup/1,ets:next_lookup/2,ets:prev_lookup/2andets:last_lookup/1. Example:ets:next_lookup/1is equivalent toets:next/2followed byets:lookup/2with the next key. The new combined functions are more efficient and with guaranteed atomicity. - OTP-18944
-
- HIGHLIGHT
The
maybeexpression is now enabled by default.To use
maybeas an atom, it needs to be single-quoted. Alternatively, themaybeexpression can be disabled by disabling themaybe_exprfeature. That can be done by placing the following the line at the beginning of an Erlang source file:-feature(maybe_expr, disable).Another way to disable the
maybe_exprfeature is by passing the-disable-featureoption toerlc:erlc -disable-feature maybe_expr some_file.erl - OTP-18951
-
- Related Id(s):
The compiler will now raise a warning when updating record/map literals. As an example, consider this module:
-module(t). -export([f/0]). -record(r, {a,b,c}). f() -> #r{a=1}#r{b=2}.The compiler raises the following warning:
1> c(t). t.erl:6:12: Warning: expression updates a literal % 6| #r{a=1}#r{b=2}. % | ^ - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-18993
-
- Related Id(s):
Optimized
ets:foldlandets:foldrto use newets:next_lookup. Also made them immune against table renaming. - OTP-19001
-
- Related Id(s):
Windows now supports all functions in
math. - OTP-19010
-
- Related Id(s):
m:erl_lint(and by extension thecompiler) will now warn for code using deprecated callbacks.The only callback currenly deprecated is
format_status/2ingen_server,gen_eventandgen_statem.You can use
nowarn_deprecated_callbackto silence the warning. - OTP-19020
-
- HIGHLIGHT
There is a new module
jsonfor encoding and decoding JSON.Both encoding and decoding can be customized. Decoding can be done in a SAX-like fashion and handle multiple documents and streams of data.
Full runtime dependencies of stdlib-6.0
compiler-5.0, crypto-4.5, erts-15.0, kernel-10.0, sasl-3.0
syntax_tools-3.2 #
- OTP-18608
-
The
epp_dodgermodule can now handle themaybeandelsekeywords. - OTP-18805
-
- Related Id(s):
Reverting a
#wrapperwill no longer throw away changes made to positions/annotations. - OTP-18715
-
- Related Id(s):
The type
erl_syntax:annotation_or_location/0is now exported. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of syntax_tools-3.2
compiler-7.0, erts-9.0, kernel-5.0, stdlib-4.0
tftp-1.2 #
- OTP-18787
-
- Related Id(s):
There is a new
tftp_loggercallback behavior module. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of tftp-1.2
erts-6.0, kernel-6.0, stdlib-5.0
tools-4.0 #
- OTP-18860
-
Dialyzer warnings due to type specs added in
dbghave been eliminated. - OTP-18998
-
In Erlang/OTP 26, doing a
coveranalysis on thelinelevel would return multiple entries for lines on which multiple functions were defined.For example, consider this module:
-module(foo). -export([bar/0, baz/0]). bar() -> ok. baz() -> not_ok.{% raw %}
In Erlang/OTP 26, analysing on the
linelevel would return two entries for line 4:1> cover:compile_module(foo). {ok,foo} 2> foo:bar(). ok 3> cover:analyse(foo, coverage, line). {ok,[{{foo,4},{1,0}},{{foo,4},{0,1}}]} 4> cover:analyse(foo, calls, line). {ok,[{{foo,4},1},{{foo,4},0}]}In Erlang/OTP 27, there will only be a single entry for line 4:
1> cover:compile_module(foo). {ok,foo} 2> foo:bar(). ok 3> cover:analyse(foo, coverage, line). {ok,[{{foo,4},{1,0}}]} 4> cover:analyse(foo, calls, line). {ok,[{{foo,4},1}]}{% endraw %}
- OTP-19026
-
- Related Id(s):
Fixed align command in emacs mode.
- OTP-18750
-
- HIGHLIGHT, POTENTIAL INCOMPATIBILITY
Triple-Quoted Strings has been implemented as per EEP 64. See String in the Reference Manual.
Example:
1> """ a b c """. "a\nb\nc"Adjacent string literals without intervening white space is now a syntax error, to avoid possible confusion with triple-quoted strings. For example:
1> "abc""xyz". "xyz". * 1:6: adjacent string literals without intervening white space - OTP-18756
-
- HIGHLIGHT
There is a new tool
tprof, which combines the functionality ofeprofandcprofunder one interface and adds heap profiling. It also has functionality to help with profiling process hierarchies.Example:
1> tprof:profile(lists, seq, [1, 16], #{type => call_memory}). ****** Process <0.92.0> -- 100.00% of total *** FUNCTION CALLS WORDS PER CALL [ %] lists:seq_loop/3 5 32 6.40 [100.00] 32 [ 100.0] ok - OTP-18856
-
- HIGHLIGHT
Native coverage support has been implemented in the JIT. It will automatically be used by the
covertool to reduce the execution overhead when running cover-compiled code.There are also new APIs to support native coverage without using the
covertool.To instrument code for native coverage it must be compiled with the
line_coverageoption.To enable native coverage in the runtime system, start it like so:
$ erl +JPcover trueThere are also the following new functions for supporting native coverage:
code:coverage_support/0code:get_coverage/2code:reset_coverage/1code:get_coverage_mode/0code:get_coverage_mode/1code:set_coverage_mode/1
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
- OTP-19080
-
- Related Id(s):
Improved the align command in emacs mode.
Full runtime dependencies of tools-4.0
compiler-8.5, erts-15.0, erts-15.0, kernel-10.0, runtime_tools-2.1, stdlib-6.0
wx-2.4.2 #
- OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of wx-2.4.2
erts-12.0, kernel-8.0, stdlib-5.0
xmerl-2.0 #
- OTP-19079
-
- POTENTIAL INCOMPATIBILITY
Some default values in Xmerl has been changed to avoid XML External Entity (XXE) vulnerabilities if you’re parsing untrusted XML.
xmerl_scan: the default value for allow_entities has changed to false. xmerl_sax_parser: the default value for external_entities has changed to none.
- OTP-19086
-
- Related Id(s):
An event state in xmerl_sax_parser which was updated in the event callback for a startEntity was not saved.
- OTP-18913
-
Function specifications and types have been added to all public API functions.
- OTP-18922
-
- Related Id(s):
As an alternative to
xmerl_xml, a new export modulexmerl_xml_indentthat provides out-of-the box indented output has been added. - OTP-18955
-
- HIGHLIGHT
The documentation has been migrated to use Markdown and ExDoc.
Full runtime dependencies of xmerl-2.0
erts-6.0, kernel-3.0, stdlib-2.5
Thanks To #
Alexander Clouter, Andrea Leopardi, Angelo Lakra, Anshul Mittal (WhatsApp), Anupama Singh, Artem Solomatin, Benjamin Philip, chiroptical, Christian Flicker, Fabian N.C. van ‘t Hooft, Frej Drejhammar, Gilbert, Guilherme Andrade, Gustaw Lippa, Ildar Khizbulin, Ilya Klyuchnikov, Ivan Sokolov, Jakub Witczak, Jan Uhlig, jdamanalo, jianhui, João Henrique Ferreira de Freitas, Johannes Christ, Jonatan Männchen, Jonathan Arnett, José Valim, Jurek Michal-AMJ018, lexprfuncall, LJZN, Luca Succi, Łukasz Niemier, Marcelino Alberdi Pereira, Maria Scott, Marko Mindek, Matthew Pope, Maxim Fedorov, Max Nordlund kivra, M-I, Michael Davis, Michal Jurek, Michal Kuratczyk, Michał Muskała, Nelson Vides, neo, Nikolay Amiantov, Paul Guyot, Paulo F. Oliveira, Richard Carlsson, Roberto Aloi, Robin Morisset, Ryota Kinukawa, Sacha, Sergey Yelin, Takeru Ohta, Tomas Abrahamsson, William Fank Thomé, WLSF, yastanotheruser, zeyun chen, Zeyu Zhang