Repository navigation
Update classgraph to 5.0.0 - #1355
Merged
Merged
Conversation
Motivation: classgraph 6.0.0 is compiled for Java 25 (class file version 69) and cannot run on Java 17. 5.0.0 targets Java 17 but has a reworked API. Modification: - Use classgraph 5.0.0 instead of 6.0.0. - Migrate test code to the 5.x API: getDirectSuperinterfaces, getAllSuperclasses and getDirectAnnotationInfo. - Pass the spec's ClassLoader via enableClassLoaders, since 5.x scans nothing unless a classpath source is enabled. - Pin classgraph to 5.x in .scala-steward.conf. Result: Test-only classgraph dependency is upgraded and still runs on Java 17. Tests: - sbt "http-tests/testOnly org.apache.pekko.http.javadsl.DirectivesConsistencySpec" (JDK 17): 321 succeeded, same as with 4.8.199 - sbt "docs/testOnly docs.ApiMayChangeDocCheckerSpec" (JDK 17): 2 succeeded, same as with 4.8.199 - scalafmt: no changes References: Refs apache#1355
pjfanning
force-pushed
the
update/classgraph-6.0.0
branch
from
October 16, 2026 16:06
91d7fca to
2ce952f
Compare
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.
Motivation
classgraph 6.0.0 is compiled for Java 25 (class file version 69,
Require-Capability: osgi.ee ... version=25) and cannot run on Java 17. 5.0.0 targets Java 17 (class file version 61) but has a reworked API, which broke compilation of the test specs.Modification
getInterfaces.directOnly→getDirectSuperinterfaces,getSuperclasses→getAllSuperclasses,MethodInfo.getAnnotationInfo→getDirectAnnotationInfo.enableClassLoaders, since 5.x scans nothing unless a classpath source is enabled.5.in.scala-steward.conf.Result
The test-only classgraph dependency is upgraded and still runs on Java 17.
Tests
sbt "http-tests/testOnly org.apache.pekko.http.javadsl.DirectivesConsistencySpec"(JDK 17): 321 succeeded, same as with 4.8.199sbt "docs/testOnly docs.ApiMayChangeDocCheckerSpec"(JDK 17): 2 succeeded, same as with 4.8.199References
None - supersedes the Scala Steward 6.0.0 update in this PR