I'm trying to execute a task within my buildscript and I'm receiving unusual errors after switching to JDK 9. I believe this has something to do with the platform modules/modules in general.
On JDK 8, the buildscript functions as expected.
Here's the error I'm getting:
> Configure project :
e: Supertypes of the following classes cannot be resolved. Please make sure you have the required dependencies in the classpath:
class org.gradle.api.Project, unresolved supertypes: Comparable<Project>
class org.gradle.api.plugins.ExtensionAware, unresolved supertypes: Object
class org.gradle.api.plugins.PluginAware, unresolved supertypes: Object
class groovy.lang.Closure, unresolved supertypes: Cloneable, Runnable, Serializable
class groovy.lang.GroovyObjectSupport, unresolved supertypes: Object
class groovy.lang.GroovyObject, unresolved supertypes: Object
class groovy.lang.GroovyCallable, unresolved supertypes: Callable<V>
class org.gradle.api.Action, unresolved supertypes: Object
class org.gradle.api.NamedDomainObjectFactory, unresolved supertypes: Object
class org.gradle.api.NamedDomainObjectSet, unresolved supertypes: Set<T>
class org.gradle.api.DomainObjectCollection, unresolved supertypes: Collection<T>
class org.gradle.util.Configurable, unresolved supertypes: Object
class org.gradle.api.Task, unresolved supertypes: Comparable<Task>
gradle generateWrapper.greeting task via gradlew greeting.Duplicate of #454
This should probably be fixed in the next release.
Hi @PavanChohan,
0.11.1 didn't ship with support for JDK 9. It will be supported in the next release.
@bamboo Do you have any idea as to when the next release will be available?
Mid-October with Gradle 4.3.
@bamboo When is support for Java 9 modules coming? Thanks.
In what respect? Can you be a bit more specific with your question?
@JLLeitschuh Essentially what I'm doing with my projects is decoupling their code into separate modules. By doing this however, modules dependent on one another aren't found on the _module-path_ because the _compileKotlin_ configuration doesn't configure it appropriately.
I've tried using the experimental Java 9 plugin but it only works for Java projects.
I guess I could try to add the compiler args myself but I'm not too knowledgeable on doing so myself.
Most helpful comment
Mid-October with Gradle 4.3.