Room Persistence Library run time exception when calling Rooms inMemoryBuilder method

I changed the 'annotationProcessor' keyword to 'kapt' in my gradle file. Like so:

kapt "android.arch.persistence.room:compiler:1.0.0"

Rule of thumb when using Kotlin:

Replace your annotationProcessor dependencies with kapt. Also, include apply plugin: 'kotlin-kapt' in your app's build.gradle.


Have a look on this thread

The solution is to replace :

annotationProcessor "android.arch.persistence.room:compiler:VERSION"

with :

kapt "android.arch.persistence.room:compiler:VERSION"