Conversation
Member
Author
|
Seems to work when scala steward runs and wants to update to latest version that is already set in the mapping it skips to create a PR because nothing changed: |
Member
Author
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
This changes how Scala Steward should handle
google-java-formatupdates in this repository.We intentionally keep the compile-time dependency in
build.sbton1.24.0, because the plugin is compiled against the Java 11-compatible API line. However, the runtime formatter selection is tracked separately through:formatterVersionForCompatibleJavaVersioninJavaFormatterPlugin.scalaREADME.mdScala Steward cannot express that policy directly by itself. If we just unpin the dependency, it would normally only update the version in
build.sbt, which is not what we want.What this does
This PR removes the Scala Steward pin for
google-java-formatand adds apostUpdateHookfor that dependency.When Scala Steward bumps the version in
build.sbt, the hook script now:google-java-formatversion frombuild.sbtbuild.sbtback to1.24.0JavaFormatterPlugin.scalaREADME.mdSo Scala Steward still uses the normal dependency update mechanism as the trigger, but the final diff is redirected to the files that actually represent the runtime formatter policy.
Why this is needed
The project currently has two different concerns:
google-java-formatreleases for newer JDKsScala Steward understands dependency versions in build files, but not this repository-specific split between compile-time and runtime formatter versions. The hook makes that policy explicit.
Note
The hook includes a comment documenting the current assumption behind this automation:
google-java-formatrelease continues to belong to the Java 21 compatibility bucketIf upstream raises the runtime requirement again in the future, the hook and compatibility policy will need to be adjusted.