Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0_第1张图片

> Task :app:compileDebugKotlin FAILED
e: D:\androidSpace\MvvpCi\app\src\main\java\dae\rounder\ui\presentation\GameListAdapter.kt: (17, 17): Unresolved reference: lifecycleOwner
e: D:\androidSpace\MvvpCi\app\src\main\java\dae\rounder\ui\presentation\PlayerListAdapter.kt: (17, 17): Unresolved reference: lifecycleOwner
e: D:\androidSpace\MvvpCi\app\src\main\java\dae\rounder\ui\presentation\PlayerStatusListAdapter.kt: (17, 17): Unresolved reference: lifecycleOwner

FAILURE: Build failed with an exception.

* What went wrong:
Execution failed for task ':app:compileDebugKotlin'.
> Compilation error. See log for more details

* 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

Deprecated Gradle features were used in this build, making it incompatible with Gradle 6.0.
Use '--warning-mode all' to show the individual deprecation warnings.
See https://docs.gradle.org/5.1/userguide/command_line_interface.html#sec:command_line_warnings

BUILD FAILED in 6s
19 actionable tasks: 1 executed, 18 up-to-date

原因:gradle版本过高

  1. 建议升级AS到3.5
  2. 修改project\gradle\wrapper\gradle-wrapper.properties 里面的distributionUrl值
  3. databinding 在gradle6.0之后做了AndroidX的不兼容更新

你可能感兴趣的:(koltin,AS,Gradle,Databinding)