-
Notifications
You must be signed in to change notification settings - Fork 0
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
Guidelines around lifecycle::badge
in teal packages
#86
Comments
Great points from @llrs-roche
We'll add this topic to the discussion. |
teal framework adheres to many tidyverse ideas, such as style and lifecycle badges. These have 4 stages thought to be used like this: Following the article I discuss how to apply the principles and ideas to the teal framework (quotes are from the stages article): Stable
I suggest to only keep the stable badge for functions (or arguments) that have left the experimental phase, and keep them for 1 year or 1 release (which ever comes earlier). Deprecated
As suggested this should only apply to functions or arguments that have replacement. This badge is used after the code has been already exposed to the user so I would keep the badge for 2 years or 2 release whichever comes later. While the project might be stuck with a given release for the duration of the project teal app developers might need time to adjust to the replacement function/argument. The first year the function or argument could be soft ExperimentalThis is the most ambiguous badge. For functions, I would only add it to those that provide a new functionality or are intended to replace existing ones, including helper functions. For arguments, I would only add it to those arguments on existing functions that provide new functionality, not renaming arguments to be more consistent, or to each argument of new (experimental) functions. An experimental function would mean all the arguments are experimental, a stable function would mean only new arguments are experimental. As the fate of an experimental functions/arguments can quickly become deprecated/removed or stable, I wouldn't limit the time to a fixed term, but I would at least leave it for 1 release or 1 year which ever comes later, to gauge feedback from users (and developers). To move to SupersededThis badge is intended only for functions that won't be removed or updated (not even arguments or behavior), once added I wouldn't remove it. It also means the function is stable and shouldn't be having breaking changes or changes of arguments. I don't think it is a good idea to promise user that a function won't be removed as this can lead to great work later on to keep the same bugs/behavior. I would only use it for very core functions ( Other considerationsAll these changes and badges are mostly considering only internal factors, the only badge affected by users feedback is the experimental badge. It is then relevant to consider how a
With what is gathered consider the impact of the changes or if something needs to be discussed with the product owner or other stakeholders. It might make sense to follow some approaches too from their design principles, this section about remediating past mistakes is relevant to lifecycle. |
from experimental to Superseded as well? |
@shajoezhu I'm not sure I follow you, but experimental arguments/functions shouldn't go to superseded according the the lifecycle and tidyverse team. Note also that this is my opinion and I've not worked on a clinical trial project using teal, my experience/opinions come from packages that are updated more frequently by users. |
I see. Thanks @llrs-roche , please ignore my comment |
Let's only focus on three badges for both function and argument:
The explanation that @llrs-roche makes sense to me (Thanks @llrs-roche!). To make the timeline easier to remember, I would use the minor version as the timeline indicator.
|
@donyunardi teal has never had any major version release, only minor releases (major.minor.patch). This would make badges and changes take very long to update, imho. I didn't specify the type of release version used and perhaps the packages are on a state that major changes should go on with major version numbers. Did you mean minor version releases? |
That's correct, I meant minor release. I updated the table. |
Team discussed the topic. Closing. |
Summary
We used
lifecycle::badge
to indicate the stage of a function (e.g., experimental, stable, deprecated, superseded).I found a past PR related to this topic:
insightsengineering/teal#456
However, we currently lack guidance on how these badges should transition from one stage to the next (i.e. from experimental to stable) or on when a badge should be removed (i.e.
teal::init
still hasstable
badge. Should it be removed?).Acceptance Criteria:
lifecycle::badge
in teal packages.The text was updated successfully, but these errors were encountered: