Kotlin gradle plugin error in Android studio 0.5.x


In android studio 0.5.x , the kotlin gradle plugin are having error. From the log, the error is inside KotlinPlugin.kt. val testSourceSet = sourceSets.getByName(BuilderConstants.INSTRUMENT_TEST)

There was exception because INSTRUMENT_TEST not found, it changed into ANDROID_TEST

and available in android builder version 0.9.0.

hopefully this can be fixed soon.



I managed to adjust the source codes and compile it against android builder 0.9.0. Not sure if this is the right way or not.

I put these jar inside my app local libs:

  • kotlin-gradle-plugin 0.1-SNAPSHOT
  • kotlin-gradle-plugin-core 0.1-SNAPSHOT
  • kotlin-stdlib 0.1-SNAPSHOT

But when i tried to do gradle sync i got this:
java.lang.NoClassDefFoundError: kotlin/jvm/internal/KObject


We are working on this problem,  you can follow this issue - http://youtrack.jetbrains.com/issue/KT-4667. Thank you!


The problem with Android Studio 0.5+ is fixed, you can use kotlin-gradle-plugin 0.7.115.


Thanks for the new version. I just tried and seems ok now.