GroovyFX build fails with Gradle 1.12 but succeeds with 1.11


(Russel Winder) #1

Build with Gradle 1.11 fine, try Gradle 1.12 and:

‘’’ 13:44:15.677 [ERROR] [org.gradle.BuildExceptionReporter] FAILURE: Build failed with an exception. 13:44:15.678 [ERROR] [org.gradle.BuildExceptionReporter]

13:44:15.678 [ERROR] [org.gradle.BuildExceptionReporter] * Where: 13:44:15.678 [ERROR] [org.gradle.BuildExceptionReporter] Build file ‘/home/users/russel/Repositories/Git/Clones/GroovyFX/build.gradle’ line: 69 13:44:15.679 [ERROR] [org.gradle.BuildExceptionReporter]

13:44:15.679 [ERROR] [org.gradle.BuildExceptionReporter] * What went wrong: 13:44:15.680 [ERROR] [org.gradle.BuildExceptionReporter] A problem occurred evaluating root project ‘GroovyFX’. 13:44:15.680 [ERROR] [org.gradle.BuildExceptionReporter] > class loader scope is locked 13:44:15.683 [ERROR] [org.gradle.BuildExceptionReporter]

13:44:15.683 [ERROR] [org.gradle.BuildExceptionReporter] * Exception is: 13:44:15.684 [ERROR] [org.gradle.BuildExceptionReporter] org.gradle.api.GradleScriptException: A problem occurred evaluating root project ‘GroovyFX’. 13:44:15.685 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:54) 13:44:15.685 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl.apply(DefaultScriptPluginFactory.java:152) 13:44:15.685 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:40) 13:44:15.686 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.project.BuildScriptProcessor.execute(BuildScriptProcessor.java:26) 13:44:15.686 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.project.ConfigureActionsProjectEvaluator.evaluate(ConfigureActionsProjectEvaluator.java:34) 13:44:15.686 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.project.LifecycleProjectEvaluator.evaluate(LifecycleProjectEvaluator.java:55) 13:44:15.686 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:493) 13:44:15.687 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.AbstractProject.evaluate(AbstractProject.java:80) 13:44:15.687 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.DefaultBuildConfigurer.configure(DefaultBuildConfigurer.java:31) 13:44:15.687 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.doBuildStages(DefaultGradleLauncher.java:142) 13:44:15.688 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.doBuild(DefaultGradleLauncher.java:113) 13:44:15.688 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.initialization.DefaultGradleLauncher.run(DefaultGradleLauncher.java:81) 13:44:15.688 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter$DefaultBuildController.run(InProcessBuildActionExecuter.java:64) 13:44:15.688 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExecuteBuildAction.run(ExecuteBuildAction.java:33) 13:44:15.689 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExecuteBuildAction.run(ExecuteBuildAction.java:24) 13:44:15.689 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:35) 13:44:15.689 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.exec.InProcessBuildActionExecuter.execute(InProcessBuildActionExecuter.java:26) 13:44:15.689 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.RunBuildAction.run(RunBuildAction.java:50) 13:44:15.690 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.internal.Actions$RunnableActionAdapter.execute(Actions.java:171) 13:44:15.690 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:201) 13:44:15.690 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$ParseAndBuildAction.execute(CommandLineActionFactory.java:174) 13:44:15.691 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:170) 13:44:15.691 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.CommandLineActionFactory$WithLogging.execute(CommandLineActionFactory.java:139) 13:44:15.691 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:33) 13:44:15.691 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.cli.ExceptionReportingAction.execute(ExceptionReportingAction.java:22) 13:44:15.692 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.Main.doAction(Main.java:46) 13:44:15.692 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.EntryPoint.run(EntryPoint.java:45) 13:44:15.693 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.Main.main(Main.java:37) 13:44:15.693 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.ProcessBootstrap.runNoExit(ProcessBootstrap.java:50) 13:44:15.693 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.bootstrap.ProcessBootstrap.run(ProcessBootstrap.java:32) 13:44:15.693 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.launcher.GradleMain.main(GradleMain.java:23) 13:44:15.694 [ERROR] [org.gradle.BuildExceptionReporter] Caused by: java.lang.IllegalStateException: class loader scope is locked 13:44:15.694 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.initialization.DefaultClassLoaderScope.export(DefaultClassLoaderScope.java:132) 13:44:15.694 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.configuration.DefaultScriptPluginFactory$ScriptPluginImpl.apply(DefaultScriptPluginFactory.java:130) 13:44:15.694 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.applyScript(DefaultObjectConfigurationAction.java:97) 13:44:15.695 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.access$000(DefaultObjectConfigurationAction.java:36) 13:44:15.695 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction$1.run(DefaultObjectConfigurationAction.java:67) 13:44:15.695 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.plugins.DefaultObjectConfigurationAction.execute(DefaultObjectConfigurationAction.java:129) 13:44:15.695 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.AbstractPluginAware.apply(AbstractPluginAware.java:35) 13:44:15.696 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.Project$apply$0.call(Unknown Source) 13:44:15.696 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.internal.project.ProjectScript.apply(ProjectScript.groovy:30) 13:44:15.696 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.api.Script$apply$0.callCurrent(Unknown Source) 13:44:15.696 [ERROR] [org.gradle.BuildExceptionReporter] at build_4edhkqdcrbssjk16j6o8j1mvsj.run(/home/users/russel/Repositories/Git/Clones/GroovyFX/build.gradle:69) 13:44:15.697 [ERROR] [org.gradle.BuildExceptionReporter] at org.gradle.groovy.scripts.internal.DefaultScriptRunnerFactory$ScriptRunnerImpl.run(DefaultScriptRunnerFactory.java:52) 13:44:15.697 [ERROR] [org.gradle.BuildExceptionReporter] … 30 more 13:44:15.697 [ERROR] [org.gradle.BuildExceptionReporter]

13:44:15.698 [LIFECYCLE] [org.gradle.BuildResultLogger]

13:44:15.698 [LIFECYCLE] [org.gradle.BuildResultLogger] BUILD FAILED 13:44:15.698 [LIFECYCLE] [org.gradle.BuildResultLogger]

‘’’

Lines 69–74 of build.gradle are:

‘’’ apply {

from ‘buildSrc/scripts/demo.gradle’

from ‘buildSrc/scripts/mavenCentralDeploy.gradle’

from ‘buildSrc/scripts/docsDependencies.gradle’

from ‘buildSrc/scripts/docs.gradle’ } ‘’’

Any help fixing this mucha ppreciated.


(Peter Niederwieser) #2

I can reproduce this reliably. Raised GRADLE-3082. Thanks for the report.


(Luke Daley) #3

About to push a fix for 2.0.

The workaround is to use individual ‘apply from: “«script»”’ statements instead of the ‘apply {}’ block style.


(Russel Winder) #4

Temporary workaround works for me, thanks Luke.


(Baiyan Huang) #5

HI, Luke - is there a patch for 1.12? I want to patch it based on 1.12, and seems there are some other commits needs to be put in as well, which brings some complexity, and my confidence of applying it upon 1.12.


(Luke Daley) #6

There won’t be a patch release for 1.12. This would be too complex to back port so I’d suggest upgrading or using the workaround above.


(Baiyan Huang) #7

Thanks Luke


(Russel Winder) #8

The GroovyFX build was amended so as to work with 1.12 as per Luke’s proposal. I have now updated to 2.0 and reverted the patches to restore the original. It all seems to work fine.