使用kotlin 0.12.213的AndroidStudio ExternalSystemException

时间:2015-06-03 19:59:29

标签: android android-studio android-gradle kotlin

环境

鉴于我有:

  1. Kotlin 0.12.213

    dependencies {
        compile fileTree(dir: 'libs', include: ['*.jar'])
        compile 'com.google.android.gms:play-services:7.5.0'
        compile 'com.android.support:appcompat-v7:22.2.0'
        compile 'com.android.support:support-v4:22.2.0'
        compile "org.jetbrains.kotlin:kotlin-stdlib:$kotlin_version"
    }
    
    buildscript {
        ext.kotlin_version = '0.12.213'
        repositories {
            mavenCentral()
        }
        dependencies {
            classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
            classpath "org.jetbrains.kotlin:kotlin-android-extensions:$kotlin_version"
        }
    }
    
  2. Gradle插件1.2.3

    classpath 'com.android.tools.build:gradle:1.2.3'
    
  3. Android Studio AI-141.1972460

  4. 问题

    当我运行我的Android应用程序时,我得到:

    com.android.ide.common.blame.output.GradleMessage$Kind PluginClassLoader[org.jetbrains.kotlin, 0.12.200.Idea141.8]
    com.intellij.openapi.externalSystem.model.ExternalSystemException: com.android.ide.common.blame.output.GradleMessage$Kind PluginClassLoader[org.jetbrains.kotlin, 0.12.200.Idea141.8]
        at org.jetbrains.plugins.gradle.service.project.GradleExecutionHelper.execute(GradleExecutionHelper.java:223)
        at com.android.tools.idea.gradle.invoker.GradleTasksExecutor.invokeGradleTasks(GradleTasksExecutor.java:400)
        at com.android.tools.idea.gradle.invoker.GradleTasksExecutor.run(GradleTasksExecutor.java:221)
        at com.intellij.openapi.progress.impl.CoreProgressManager$TaskRunnable.run(CoreProgressManager.java:563)
        at com.intellij.openapi.progress.impl.CoreProgressManager$2.run(CoreProgressManager.java:152)
        at com.intellij.openapi.progress.impl.CoreProgressManager.registerIndicatorAndRun(CoreProgressManager.java:452)
        at com.intellij.openapi.progress.impl.CoreProgressManager.executeProcessUnderProgress(CoreProgressManager.java:402)
        at com.intellij.openapi.progress.impl.ProgressManagerImpl.executeProcessUnderProgress(ProgressManagerImpl.java:54)
        at com.intellij.openapi.progress.impl.CoreProgressManager.runProcess(CoreProgressManager.java:137)
        at com.intellij.openapi.progress.impl.ProgressManagerImpl$1.run(ProgressManagerImpl.java:126)
        at com.intellij.openapi.application.impl.ApplicationImpl$8.run(ApplicationImpl.java:400)
        at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:511)
        at java.util.concurrent.FutureTask.run(FutureTask.java:266)
        at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1142)
        at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:617)
        at java.lang.Thread.run(Thread.java:745)
        at org.jetbrains.ide.PooledThreadExecutor$1$1.run(PooledThreadExecutor.java:56)
    

    变通方法

    1. 目前在AndroidStudio 1.3预览版上运行我的应用程序的唯一方法是关闭AndroidStudio并在每次运行应用程序时再次打开它。否则,后续运行会抛出上述异常。 无效cahcnes / restart,没有解决问题。

    2. 只需使用AndroidStudio 1.2.1.1,因为那里不存在问题。

1 个答案:

答案 0 :(得分:3)

这已在Kotlin 0.12.356中修复。您可以在相应的问题中看到讨论:KT-7862