org.gradle.api.GradleException: ошибка компиляции - PullRequest
0 голосов
/ 08 февраля 2019

пока я исключаю свое приложение, сгенерирована следующая ошибка.

org.gradle.api.tasks.TaskExecutionException: не удалось выполнить задачу ': app: compileDebugKotlin'.в org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions (ExecuteActionsTaskExecuter.java:110) в org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.execute:gra.grag: at77).api.internal..tasks.execution.ResolveTaskOutputCachingStateExecuter.execute (ResolveTaskOutputCachingStateExecuter.java:54) в org.gradle.api.internal.tasks.execution.ValidatingTaskExecuter.execute.a.as.gra..SkipEmptySourceFilesTaskExecuter.execute (SkipEmptySourceFilesTaskExecuter.java:101) в org.gradle.api.internal.tasks.execution.FinalizeInputFilePropertiesTaskExecuter.execute (FinalizeInputFileProgra.jpg) org.jpg.api.internal..tasks.execution..ExecuteAtMostOnceTaskExecuter.execute (ExecuteAtMostOnceTaskExecuter.java:43) в org.gradle.api.internal.tasks.execution.CatchExceptionTaskExecuter.execute (CatchExceptionTaskExecuter.java:34) в org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter $ 1.выполнить (EventFiringTaskExecuter.java:51) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:300) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:292) в org.gradle.internal.operations.DefaultBuildOperationExecutor.execute (DefaultBuildOperationExecutor.java:174) в org.gradle.internal.operationuOgnoв org.gradle.internal.operations.DelegatingBuildOperationExecutor.run (DelegatingBuildOperationExecutor.java:31) в org.gradle.api.internal.tasks.execution.EventFiringTaskExecuter.execute (EventFiringTaskExecuter.java.gra.grade.graph) at)..LocalTaskInfoExecutor.execute (LocalTaskInfoExecutor.java:42) в org.gradle.execution.taskgraph.DefaultTaskExecutionGraph $ BuildOperationAwareWorkItemExecutor.execute (DefaultTaskExecutionGraph.java:277) в org.gradle.execution.taskgraph.DefaultTaskExecutionGraph $ BuildOperationAwareWorkItemExecutor.execute (DefaultTaskExecutionGraph.java: 262) at org.gradle.execution.taskgraph.DefaultTaskPlanExecutor $ ExecutorWorker $ 1.execute (DefaultTaskPlanExecutor.java:135) в org.gradle.execution.taskgraph.DefaultTaskPlanExecutor $ ExecutorWorker $ 1.execute (DefaultTaskPlanExecutor.java:130) в org.gradle.execution.taskgraph.DefaultTaskexplanExecutor $ Executor.ecorg.gradle.execution.taskgraph.DefaultTaskPlanExecutor $ ExecutorWorker.executeWithWork (DefaultTaskPlanExecutor.java:191) в org.gradle.execution.taskgraph.DefaultTaskPlanExecutor $ ExecutorWorker.rdlek_exase.grandDefaultTaskPlanExecutor.process (DefaultTaskPlanExecutor.java:74)в org.gradle.execution.taskgraph.DefaultTaskExecutionGraph.execute (DefaultTaskExecutionGraph.java:143) в org.gradle.execution.SelectedTaskExecutionAction.execute (SelectedTaskExecutionAction.exava.java:40) build_Exu.: 40) в org.gradle.execution.DefaultBuildExecuter.access $ 000 (DefaultBuildExecuter.java:24) в org.gradle.execution.DefaultBuildExecuter $ 1.proceed (DefaultBuildExecuter.java:46) в org.graecu.execution.DryRuntectionDryRunBuildExecutionAction.java:49) в org.gradle.execution.DefaultBuildExecuter.execute (DefaultBuildExecuter.java:40) в org.gradle.execution.DefaultBuildExecuter.execute (DefaultBuildExecuter.java:33) в точке сближения..run (DefaultGradleLauncher.java:355) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:300) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:292) в org.gradle.internal.operations.DefaultBuildOperationExecutor.execute (DefaultBuildOperationExecutor.java:174) в org.gradle.inperationOu.Uuпо адресу org.gradle.internal.operations.DelegatingBuildOperationExecutor.run (DelegatingBuildOperationExecutor.java:31) по адресу org.gradle.initialization.DefaultGradleLauncher.runTasks (DefaultGradleLauncher.java:219) по умолчанию149$ 1.call (GradleBuildController.java:74) в org.gradle.internal.work.DefaultWorkerLeaseService.withLocks (DefaultWorkerLeaseService.java:154) в org.gradle.internal.work.StopShieldingWorkerLeaseService.withLocks (StopShieldingWorkerLeaseService.java:38) в org.gradle.internal.invocation.GradleBuildController.doButernal.ontra..run (GradleBuildController.java:74) в org.gradle.tooling.internal.provider.runner.ClientProvidedBuildActionRunner.run (ClientProvidedBuildActionRunner.java:68) в org.gradle.launcher.exe.ChainingBununAuction) в org.gradle.launcher.exec.ChainingBuildActionRunner.run (ChainingBuildActionRunner.java:35) в org.gradle.tooling.internal.provider.ValidatingBuildActionRunner.run (ValidatingBuildActionRunner.java.exegra.lag.rag.uncher или org.RunAsBuildOperationBuildActionRunner $ 3.run (RunAsBuildOperationBuildActionRunner.java:50) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.inggrag) :300operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:292) в org.gradle.internal.operations.DefaultBuildOperationExecutor.execute (DefaultBuildOperationExecutor.java:174.jefExo.Operation.Ou90) в org.gradle.internal.operations.DelegatingBuildOperationExecutor.run (DelegatingBuildOperationExecutor.java:31) в org.gradle.launcher.exec.RunAsBuildOperationBuildActionRunner.run (RunAsBuildOperationBuildActionRternalin.g.av.g.inv.inv.inv.g)..SubscribeableBuildActionRunner.run (SubscribeableBuildActionRunner.java:51) в org.gradle.launcher.exec.InProcessBuildActionExecuter $ 1.transform (InProcessBuildActionExecuter.java:47)по адресу org.gradle.launcher.exec.InProcessBuildActionExecuter $ 1.transform (InProcessBuildActionExecuter.java:44) по адресу org.gradle.composite.internal.DefaultRootBuildState.run (DefaultRootBuildState.java:79) в org.graildAвыполнить (InProcessBuildActionExecuter.java:44) по адресу org.gradle.launcher.exec.InProcessBuildActionExecuter.execute (InProcessBuildActionExecuter.java:30) по адресу org.gradle.launcher.exec.BuildTreeScopeBuildActionExecuter.exdle.graExuter.uj.jpg,(ContinuousBuildActionExecuter.java:53) в org.gradle.tooling.internal.provider.ServicesSetupBuildActionExecuter.execute (ServicesSetupBuildActionExecuter.java:62) в org.gradle.Инструментарийвыполнить (GradleThreadBuildActionExecuter.java:25) по адресу org.gradle.tooling.internal.provider.ParallelismConfigurationBuildActionExecuter.execute (ParallelismConfigurationBuildActionExecuter.java:43) в org.gradle.tool.Exj.Exj.Exception.в org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.execute (StartParamsValidatingActionExecuter.java:59) в org.gradle.tooling.internal.provider.StartParamsValidatingActionExecuter.graVid..provider.SessionFailureReportingActionExecuter.execute (SessionFailureReportingActionExecuter.java:59) в org.gradle.tooling.internal.provider.SessionFailureReportingActionExecuter.execute (SessionFailureReportingActionExecuter.java:44) в org.gradle.tooling.internal.provider.SetupLoggingAction.gradle.tooling.internal.provider.SetupLoggingActionExecuter.execute (SetupLoggingActionExecuter.java:30) в org.gradle.launcher.daemon.server.exec.ExecuteBuild.doBuild (ExecuteBuild.java:67) в org.gradle.laher.server.exec.BuildCommandOnly.execute (BuildCommandOnly.java:36) в org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org.gradle.launcver.mon.WatchForDisconnection.execute (WatchForDisconnection.java:37) по адресу org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) по адресу org.gradle.launcher.daemon.exogserReResetReader.Regservice.Exserc.Reader.Reader.Exchange.c.(ResetDeprecationLogger.java:26) в org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org.gradle.launcher.daemon.server.exec.RequestStopIfSingleUsedDaemon.execute (RequestStopIfSingleUsedDaemon.mon.gra.gra.gra.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org.gradle.launcher.daemon.server.exec.ForwardClientInput $ 2.call (ForwardClientInput.java:74) в org.gradle.launcher.daemon.ser.exe.ForwardClientInput $ 2.call (ForwardClientInput.java:72) в org.gradle.util.Swapper.swap (Swapper.java:38) в org.gradle.launcher.daemon.server.exec.ForwardClientInput.execute (ForwardClientInput.java:72) в org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org.gradle.launcher.daemon.server.exec.LogAndCheckHealth.execute (LogAndCheckHealth.jj)на org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) на org.gradle.launcher.daemon.server.exec.LogToClient.doBuild (LogToClient.java:62g) или.launcher.daemon.server.exec.BuildCommandOnly.execute (BuildCommandOnly.java:36) в org.gradle.launcher.daemon.server.api.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org..server.exec.EstablishBuildEnvironment.doBuild (EstablishBuildEnvironment.java:81) в org.gradle.launcher.daemon.server.exec.BuildCommandOnly.execute (BuildCommandOnly.java:36) в org.gradle.launcver.apimon.DaemonCommandExecution.proceed (DaemonCommandExecution.java:122) в org.gradle.launcher.daemon.server.exec.StartBuildOrRespondWithBusy $ 1.run (StartBuildOrRespondWithBusy.java:50).(DaemonStateCoordinator.java:295) в org.gradle.internal.concurrent.ExecutorPolicy $ CatchAndRecordFailures.onExecute (ExecutorPolicy.java:63) в org.gradle.internal.concurrent.ManagedExecutorImpl $ 1.run (ManagedExecutorImpl.java:46) в java.util.concurrent.ThreadPoolExecutor.runWorker (ThreadPoolExecutor.java:1142) в java.u.ThreadPoolExecutor $ Worker.run (ThreadPoolExecutor.java:617) в org.gradle.internal.concurrent.ThreadFactoryImpl $ ManagedThreadRunnable.run (ThreadFactoryImpl.java:55) в java.lang.Thread.run (Thread.java by7): 7: org.gradle.api.GradleException: ошибка компиляции.Более подробную информацию смотрите в журнале org.jetbrains.kotlin.gradle.tasks.TasksUtilsKt.throwGradleExceptionIfError (tasksUtils.kt: 14) по адресу org.jetbrains.kotlin.compilerRunner.GradleKotlinCompilerWork.run (GradleKotbin.omp): 135kotlin.compilerRunner.GradleCompilerRunner.runCompilerAsync (GradleKotlinCompilerRunner.kt: 152) в org.jetbrains.kotlin.compilerRunner.GradleCompilerRunner.runCompilerAsync (GradleKotlinCompilerRunner.kt: 147) в org.jetbrains.kotlin.compilerRunner.GradleCompilerRunner.runJvmCompilerAsync (GradleKotlinCompilerRunner.kt:87) в org.jetbrains.kotlin.gradle.tasks.KotlinCompile.callCompilerAsync $ kotlin_gradle_plugin (Tasks.kt: 409) в org.jetbrains.kotlin.gradle.tasks.KotlinCompile.callCompilerAsyndle_grag_gg_tg.jetbrains.kotlin.gradle.tasks.AbstractKotlinCompile.execute (Tasks.kt: 276) в sun.reflect.NativeMethodAccessorImpl.invoke0 (родной метод) в sun.reflect.NativeMethodAccessorImpl.invoke (исходный.refle.DelegatingMethodAccessorImpl.invoke (DelegatingMethodAccessorImpl.java:43) в java.lang.reflect.Method.invoke (Method.java:498) в org.gradle.internal.reflect.JavaMethod.invoke (JavaMethod) или JavaMethod..gradle.api.internal.project.taskfactory.IncrementalTaskAction.doExecute (IncrementalTaskAction.java:50) в org.gradle.api.internal.project.taskfactory.StandardTaskAction.execute (StandardTaskAction.java.gra.grag или atg)..internal.project.taskfactory.StandardTaskAction.execute (StandardTaskAction.java:26) в org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter $ 1.run (ExecuteActionsTaskExecuter.java:1dleo.in.gra.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutor.java:300) в org.gradle.internal.operations.DefaultBuildOperationExecutor $ RunnableBuildOperationWorker.execute (DefaultBuildOperationExecutordle.perationBeoGuperистationExecutor.java:174) в org.gradle.internal.operations.DefaultBuildOperationExecutor.run (DefaultBuildOperationExecutor.java:90) в org.gradle.internal.operations.DelegatingBuildOperationExecutor.run (DelegatingBuildOperationExdleapg).internal.tasks.execution.ExecuteActionsTaskExecuter.executeAction (ExecuteActionsTaskExecuter.java:120)at org.gradle.api.internal.tasks.execution.ExecuteActionsTaskExecuter.executeActions (ExecuteActionsTaskExecuter.java:99) ... еще 115

1 Ответ

0 голосов
/ 08 февраля 2019

Важнейшая часть вашего вывода:

Вызывается: org.gradle.api.GradleException: Ошибка компиляции.Более подробную информацию смотрите в журнале

Этот сбой в выполнении задачи означает, что компилятор Kotlin завершился ошибкой и возвратил ошибку.

Обычно можно найти описание ошибки и местонахождение проблемного кода.в журнале Gradle выше, где агрегируется журнал задачи :app:compileDebugKotlin.

Вот пример выходных данных (примечание: я не добавил --stacktrace, поэтому Gradle не печатает всю трассировку стекаисключение выдается задачей):

> Task :compileKotlinJvm6 FAILED
e: /mnt/c/foo/Foo.kt: (3, 1): Modifier 'expect' is incompatible with 'actual'
e: /mnt/c/foo/Foo.kt: (3, 8): Modifier 'actual' is incompatible with 'expect'

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':compileKotlinJvm6'.
> Compilation error. See log for more details

В ваших журналах ищите строки, начинающиеся с e:, вот как компилятор сообщает об ошибках.

Добро пожаловать на сайт PullRequest, где вы можете задавать вопросы и получать ответы от других членов сообщества.
...