-
Notifications
You must be signed in to change notification settings - Fork 593
🌱 New check: Mean time to update dependencies #4868
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
base: main
Are you sure you want to change the base?
Conversation
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #4868 +/- ##
==========================================
+ Coverage 66.80% 68.42% +1.62%
==========================================
Files 230 259 +29
Lines 16602 16147 -455
==========================================
- Hits 11091 11049 -42
+ Misses 4808 4214 -594
- Partials 703 884 +181 🚀 New features to boost your workflow:
|
Signed-off-by: Adam Korczynski <adam@adalogics.com>
a6b5687 to
7a015f1
Compare
Agreed. Seems like a good usage of existing libraries to do the heavy lifting for us.
Also agree generally.
Any idea how major versions work with scalibr parsing or version reporting from deps dev? These might be heavier lifts than a minor/patch update. One reservation with this check is it might encourage upgrade churn for the purpose of churn. But this puts it in a similar boat as the dependency upgrade tool check. For these situational checks, I think we benefit from having the customizability in place and considering what runs by default. |
|
Something to consider for .NET if it isn't accounted for already, is that libraries may match the dependencies for different target frameworks to the specific major version they target to maximise compatibility. For example, if a library targets In that scenario, I wouldn't expect a library to be marked down for using Microsoft will still support the latest patch version of each major version during their support lifetime (which overlap). For a specific example, if a project was using System.Text.Json@8.0.6, which is the most up-to-date version for .NET 8, it shouldn't be penalised for not using System.Text.Json@9.0.0 which was released on 2024-11-12 (394 days ago as of writing). Separately, there's also the question of whether a library that "pins" a version because it wants to maintain compatibility and leave what the specific version used at runtime is to the consuming application should be penalised for doing so. The example of that would be similar to above, except |
What kind of change does this PR introduce?
New check
This PR adds a new check with 3 underlying probes to scorecard. The check is an implementation of #2458. In essence, the check works like this:
As such, the check considers the negative findings in a project - the dependencies that have not been updated to its latest version - and the check can be considered one that reports how old a project's dependencies are rather than providing a full picture of how quickly a project updates its dependencies.
A few notes on implementation details:
PR title follows the guidelines defined in our pull request documentation
Tests for the changes have been added (for bug fixes/features)
Which issue(s) this PR fixes
Fixes #2458
Special notes for your reviewer
I would recommend reading the documentation in the
.yml and .yamlfiles in this PR and testing the check withgo run main.go --repo=github.com/owner/repo --checks=MTTUDependenciesbefore reviewing the code.Does this PR introduce a user-facing change?
For user-facing changes, please add a concise, human-readable release note to
the
release-note(In particular, describe what changes users might need to make in their
application as a result of this pull request.)