问题:
Build failed:“Conflict with dependency 'com.android.support:support-annotations' in project ':mobile'. Resolved versions for app (26.1.0) and test app (27.1.1) differ.”
mobile的build.gradle如下
解决办法:
1.
implementation 'com.android.support:appcompat-v7:26.1.0'修改为28.0.0,
compileSdkVersion和targetSdkVersion都修改为28
再删除implementation 'com.google.android.gms:play-services-wearable:+'
2.
如果需要保留implementation 'com.google.android.gms:play-services-wearable:+'
appcompat的版本不能修改为高版本,所需要为添加配置:
configurations.all {
resolutionStrategy.force 'com.android.support:support-annotations:26.1.0'
}
再同步后rebuild