Error Kotlin does not find bytecode for lambda function: "Failed to find byte code for java / util / function / BiConsumer"

1

When I try to run my app on my phone (the same thing happens in the emulator), the following error occurs:

Error:FAILURE: Build failed with an exception.

* What went wrong: 
Execution failed for task ':app:transformClassesWithInstantRunForDebug'.
> com.android.build.api.transform.TransformException: 
java.lang.RuntimeException: java.lang.RuntimeException: java.io.IOException: 
Failed to find byte code for java/util/function/BiConsumer

* Try:
 Run with --stacktrace option to get the stack trace. Run with --info or --
 debug option to get more log output. Run with --scan to get full insights.

* Get more help at https://help.gradle.org

BUILD FAILED in 3m 4s

"Solutions" that I've tried but did not work:

  • Update Android Studio (Canary 6),

  • Update Kotlin (1.2.10),

  • Update Gradle (3.1.0-alpha06),

  • Add Multidex dependency

asked by anonymous 29.12.2017 / 13:41

1 answer

1

Try disabling Instant Run on

Preferences > Build, Execution, Deployment

It was the only thing that worked for me!

    
27.04.2018 / 17:00