Missing javaCompileTask for variant
Asked Answered
E

4

5

Trying to build something with Android Studio 3.0 that worked fine in a previous version. Now I am seeing:

Error:Execution failed for task ':mobile-app:transformClassesWithRetrolambdaForDevDebug'.

Missing javaCompileTask for variant: dev/debug/0 from output dir: /Users/myname/mycompany-android-app/MyProject/mobile-app/build/intermediates/transforms/retrolambda/dev/debug/0

I had a prior compile issue I got around by the adding the following to my module level build.gradle inside of defaultConfig:

javaCompileOptions { annotationProcessorOptions { includeCompileClasspath false } }

I can't find much of anything on "javaCompileTask". Maybe that relates to something else?

Empoverish answered 13/6, 2017 at 14:47 Comment(0)
E
8

I ended up commenting out the apply plugin for the retro lambda and that did it.

Empoverish answered 13/6, 2017 at 20:37 Comment(0)
N
6

I tried to use retrolambda version 3.6.1 with Android Gradle plugin 3.0.0-alpha5 and it does works. This is an issue with Android Gradle plugin 3.0.0-alpha* version.

Reference:

Does not currently work with the Retrolambda plugin. However, you should instead use the plugin's built-in support for Java 8 language features.

Documented in the Known Issues section at https://developer.android.com/studio/preview/features/new-android-plugin.html

Nuptials answered 5/7, 2017 at 19:34 Comment(0)
N
1

I have same problem and refer to library https://github.com/evant/gradle-retrolambda

I'm just add below line to dependencies

classpath 'me.tatarka:gradle-retrolambda:3.7.0'

And remove this

plugins {
     id "me.tatarka.retrolambda" version "3.7.0"
}
Niobium answered 8/9, 2018 at 13:42 Comment(0)
P
-1

search me.tatarka.retrolambda everywhere or its subarray and comment it in 2 files named build.gradle. this error was due to that you have install the update in gradle you will be able to run your android app.

Perverse answered 21/8, 2018 at 13:30 Comment(0)

© 2022 - 2024 — McMap. All rights reserved.