[erlang-questions] Erlang 21, Stability and the murder of an innocent Statemachine

Mike French mfrench@REDACTED
Mon May 7 10:13:49 CEST 2018


So you have

-          ‘soft-deprecation’  with doc notes, but no compiler warnings

-          ‘hard-deprecation’ with compiler warnings, but no feature removal


I suggest the third stage would be:

-          ‘end-of-life’ with compiler warnings, and there is a
known future release when the original feature will vanish

Mike


From: erlang-questions-bounces@REDACTED [mailto:erlang-questions-bounces@REDACTED] On Behalf Of José Valim
Sent: Monday, May 07, 2018 9:55 AM
To: Lloyd R. Prentice <lloyd@REDACTED>
Cc: erlang-questions@REDACTED Questions <erlang-questions@REDACTED>
Subject: Re: [erlang-questions] Erlang 21, Stability and the murder of an innocent Statemachine


What about documentation from the OTP team that outlines a deprecation policy? It may be a good opportunity to also outline other compatibility guarantees, such as the compiled bytecode guarantees and the node compatibility guarantees, if such are not yet documented.

We did define such document not long ago for Elixir. In terms of deprecations, we have two terms: "soft-deprecation" and "hard-deprecation". The soft-deprecation is added as soon as a new implementation exists. At this point we don't emit any warnings, but we do update the docs to say the feature will warn in the future and start to point folks towards better ways.

A hard-deprecation is when we finally start emitting warnings. A hard-deprecation can only be added after an alternative exists for at least 2 Elixir releases. This is very important because it means that, once a feature is hard deprecated, you know you can use the proposed alternative and that alternative is supported at least two versions back.

This is only necessary if a feature is being replaced. In case a feature is being removed, such as non-smp VM versions, you may skip directly to the "hard-deprecation" and emit warnings straight-away since there won’t be an alternative in the future anyway.

I am not proposing for Erlang/OTP team to follow those rules and conventions but writing *some* rules as minimum guarantees may improve communication and help the community plan in terms of warnings, deprecations and removals accordingly. I would just avoid emitting deprecation warnings in the same version that an alternative is introduced, because it means library developers need to either only support the latest version or introduce conditionals (either at compile-time or runtime) to support multiple versions.

José Valim
www.plataformatec.com.br<http://www.plataformatec.com.br/>
Founder and
Director of R&D

--


José Valim
www.plataformatec.com.br<http://www.plataformatec.com.br/>
Founder and
Director of R&D
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://erlang.org/pipermail/erlang-questions/attachments/20180507/09b92629/attachment.htm>


More information about the erlang-questions mailing list