android-studiokotlinandroid-gradle-pluginandroid-gradle-3.0

> Could not create task ':app:compileDebugKotlin'. > Could not create task ':app:dataBindingGenBaseClassesDebug'


When i build the app i got error

> Could not create task ':app:compileDebugKotlin'.
> Could not create task ':app:dataBindingGenBaseClassesDebug'.
> Cannot use @TaskAction annotation on method DataBindingGenBaseClassesTask.writeBaseClasses() because interface org.gradle.api.tasks.incremental.IncrementalTaskInputs is not a valid parameter to an action method.

Solution

  • I got the same error when I set the Gradle version as 8.0 milestone-5 in the Project Structure...-> Project. Changing on 7.6 version fixed the issue.