Android Studio新建项目gradle编译错误:Conflict with dependency com.android.support:support-annotations解决办法
程序员文章站
2024-03-25 11:16:04
...
1.报错提示
Error:Execution failed for task ':app:preDebugAndroidTestBuild'.
> Conflict with dependency 'com.android.support:support-annotations' in project ':app'. Resolved versions for app (26.1.0) and test app (27.1.1) differ. See https://d.android.com/r/tools/test-apk-dependency-conflicts.html for details.
2.解决办法,找到build.gradle文件操作如下图