Keeping IntelliJ Kotlin plugin and code in sync


Hi there,

So I have two scenarios that are problematic yet extremely common, in my experience.

  1. Kotlin plugin updates before I’m ready or able to update the Kotlin runtime I’m actually compiling against. e.g. kotlin plugin is 1.0.4 but I’m still using 1.0.3.
  2. I have multiple projects – one on 1.0.4, one on 1.0.3. If the Kotlin plugin is on either the 1.0.3 or 1.0.4, one of the projects isn’t going to work properly.

I’ve noticed that if the Kotlin plugin and Kotlin runtime don’t match, all sorts of weird plugin exceptions get thrown.

The problem is that the plugin seems to be tied to particular versions of Kotlin, and also can’t be easily downgraded. What we really need, I believe, is either a) for the Kotlin plugin to function properly with all preceding versions of Kotlin, or b) to be able to tie the version of the Kotlin plugin to particular projects (or even modules).

Has this problem been discussed anywhere previously? It makes it rather challenging to work on projects where said projects can’t necessarily be updated as soon as a new version of Kotlin comes out. I’m especially concerned now that 1.1 is going to be released sometime soonish (I’m presuming).


How to downgrade to Kotlin plugin 1.0.x?

Could you provide some specifics, what problems do you face when using 1.0.4 compiler with 1.0.3 runtime?

Runtime doesn’t change much across 1.0.x versions, and you should be able to use 1.0.4 plugin/compiler to compile against any of previous 1.0.x runtime versions.