I'm not sure that this is really a bug but it didn't feel like a feature request either.
Using the Gradle plugin with Gradle 8.2-rc-1 results in the following deprecation warning:
The Project.getConvention() method has been deprecated. This is scheduled to be removed in Gradle 9.0. Consult the upgrading guide for further information: https://docs.gradle.org/8.2-rc-1/userguide/upgrading_version_8.html#deprecated_access_to_conventions
at org.gradle.api.internal.project.DefaultProject.getConvention(DefaultProject.java:593)
at org.graalvm.buildtools.gradle.NativeImagePlugin.configureJavaProject(NativeImagePlugin.java:264)
at org.graalvm.buildtools.gradle.NativeImagePlugin.lambda$apply$0(NativeImagePlugin.java:201)
Given the Gradle 7.4 baseline, it looks like project.getExtensions().getByType(JavaPluginExtension.class) and JavaPluginExtension.getSourceSets() can be used as a direct replacement for the current JavaPluginConvention usage:
I'm not sure that this is really a bug but it didn't feel like a feature request either.
Using the Gradle plugin with Gradle 8.2-rc-1 results in the following deprecation warning:
Given the Gradle 7.4 baseline, it looks like
project.getExtensions().getByType(JavaPluginExtension.class)
andJavaPluginExtension.getSourceSets()
can be used as a direct replacement for the currentJavaPluginConvention
usage:https://github.com/graalvm/native-build-tools/blob/71c741a173c6c08e7d97c29d857babdcb10f350d/native-gradle-plugin/src/main/java/org/graalvm/buildtools/gradle/NativeImagePlugin.java#L263-L264