-
Notifications
You must be signed in to change notification settings - Fork 18
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Exception when executing with --info #36
Comments
Any other details ? Which Gradle version ? Do you have a basic build.gradle project that can reproduce this exception. |
I encountered the same issue after performing the following upgrades: org.unbroken-dome.xjc: 1.4.3 -> 2.0.0 Issue: As mentioned by @inidona, the error is in the logging line at AbstractXjcGeneratorWorkAction.kt:159. parameters.catalogResolvedArtifacts is null, therefore parameters.catalogResolvedArtifacts.get() throws the NPE. There is a workaround for this issue by adding catalogResolutionClasspath = sourceSets.main.compileClasspath in the custom xjcGenerate2 task. |
If you did not have that custom task, does it run and run without error? even if the extra task was not executed, the introduction (default initialization) of the custom XJC Plugin task is necessary to trigger the problem ? Can you share the XJC plugin parts of your gradle.build file ? Maybe it needs to initialize to an empty collection (original reporter indicates the fatal error only occurs with --info which I assume is a logging matter), or inherit a value, or default to the current sourceSets ("main" in the example you presented) and lookup the relevant "compileClasspath" collection. Does your project also work as expected if you initialize it to an empty collection ? If you are able to share gradle.build fragment please describe the intention being achieved, so that is clear to all. Thanks |
`xjcGenerate { tasks.register('xjcGenerate2', XjcGenerate) { It works fine without this custom task even if this task wasn't executed. |
I got the following exception when running the generation with --info switch enabled.
Without --info generation works as expected.
I am using the version 2.0.0 of your plugin.
I looks like the error is in the logging line at
AbstractXjcGeneratorWorkAction.kt:159)
thanks
andreas
Caused by: org.gradle.workers.internal.DefaultWorkerExecutor$WorkExecutionException: A failure occurred while executing org.unbrokendome.gradle.plugins.xjc.work.xjc23.XjcGeneratorWorkAction
Caused by: org.gradle.api.internal.provider.MissingValueException: Cannot query the value of this property because it has no value available.
at org.gradle.api.internal.provider.AbstractMinimalProvider.get(AbstractMinimalProvider.java:86)
at org.unbrokendome.gradle.plugins.xjc.work.common.AbstractXjcGeneratorWorkAction.buildOptions(AbstractXjcGeneratorWorkAction.kt:159)
at org.unbrokendome.gradle.plugins.xjc.work.common.AbstractXjcGeneratorWorkAction.execute(AbstractXjcGeneratorWorkAction.kt:31)
at org.gradle.workers.internal.DefaultWorkerServer.execute(DefaultWorkerServer.java:63)
at org.gradle.workers.internal.AbstractClassLoaderWorker$1.create(AbstractClassLoaderWorker.java:49)
at org.gradle.workers.internal.AbstractClassLoaderWorker$1.create(AbstractClassLoaderWorker.java:43)
at org.gradle.internal.classloader.ClassLoaderUtils.executeInClassloader(ClassLoaderUtils.java:97)
at org.gradle.workers.internal.AbstractClassLoaderWorker.executeInClassLoader(AbstractClassLoaderWorker.java:43)
at org.gradle.workers.internal.IsolatedClassloaderWorker.run(IsolatedClassloaderWorker.java:49)
at org.gradle.workers.internal.IsolatedClassloaderWorker.run(IsolatedClassloaderWorker.java:30)
The text was updated successfully, but these errors were encountered: