@OnClick method from Butterknife crashes app with java.lang.BootstrapMethodError
I was facing the same problem. Butter Knife requires that you enable Java 8 in your builds to function as of version 9.0.0 and newer. This is what worked for me ....
app.gradle
android {
compileOptions {
sourceCompatibility JavaVersion.VERSION_1_8
targetCompatibility JavaVersion.VERSION_1_8
}
}
dependencies {
implementation 'com.jakewharton:butterknife:10.1.0'
annotationProcessor 'com.jakewharton:butterknife-compiler:10.1.0'
}
apply plugin: 'com.jakewharton.butterknife'
https://developer.android.com/studio/write/java8-support
Sync your gradle file if you are still facing the problem, clean your project and run again.
I solved it by downgrading the library version.
I replaced the following
implementation 'com.jakewharton:butterknife:9.0.0-rc3'
annotationProcessor 'com.jakewharton:butterknife-compiler:9.0.0-rc3'
with
implementation 'com.jakewharton:butterknife:9.0.0-rc1'
annotationProcessor 'com.jakewharton:butterknife-compiler:9.0.0-rc1'