Skip to content

Conversation

@rtyley
Copy link
Contributor

@rtyley rtyley commented Nov 28, 2025

@rtyley rtyley force-pushed the add-dependency-cooldowns branch from bc0d61f to f7dc7c0 Compare November 28, 2025 11:53
@codecov
Copy link

codecov bot commented Nov 28, 2025

Codecov Report

❌ Patch coverage is 92.85714% with 1 line in your changes missing coverage. Please review.
✅ Project coverage is 89.84%. Comparing base (aa5f323) to head (f7dc7c0).
⚠️ Report is 8 commits behind head on main.

Files with missing lines Patch % Lines
...org/scalasteward/core/coursier/VersionsCache.scala 90.90% 1 Missing ⚠️
Additional details and impacted files
@@           Coverage Diff           @@
##             main    #3762   +/-   ##
=======================================
  Coverage   89.84%   89.84%           
=======================================
  Files         174      174           
  Lines        5043     5053   +10     
  Branches      451      464   +13     
=======================================
+ Hits         4531     4540    +9     
- Misses        512      513    +1     

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

It looks like we probably want to update UpdatesConfig.scala to add a
new method `isTooNew: Update.ForArtifactId => FilterResult` which rules
out proposed updates that use too new a version (according to the user’s
config).

To do that, we reckon we’ll need Update.ForArtifactId to list versions
with their firstSeen information, i.e. update the contained type from
Version to VersionWithFirstSeen. This commit begins making that
change (and so will not compile).
This commit removes withNewerVersions and replaces the one usage of it
with a new function supersedes, which checks whether an update matches
another while having a newer nextVersion.

withNewerVersions was a little awkward to update to work with us having
changed some Versions to VersionWithFirstSeens, because it accepts a
list of Versions (rather than just producing one).

It was originally added in response to [this PR
comment](scala-steward-org#1667 (comment)),
but we reckon replacing it with a slightly different check of the
group and artifact IDs makes for clearer, more explicit code. We
think (though it’s somewhat hard to tell) that this doesn’t remove any
existing functionality: part of the argument for adding
withNewerVersions in the first place was to support Update.Group, but it
appears to only be called for Update.Singles.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants