在android gradle中意味着什么。
添加 // noinspection GradleCompatible 解决了依赖项的冲突问题。
答案 0 :(得分:2)
答案 1 :(得分:0)
我遇到了同样的问题,最后我通过按alt+enter
添加了这一行,但在此之前,请检查应用程序兼容库版本是否为可用于您应用程序目标sdk版本的最新版本。
如果还可以,但是仍然存在问题,请通过按alt+enter
键(在 ubuntu 和 windows 中)和(在mac os中(os x)使用命令+ shift + enter)添加noinspection GradleCompatible
会有所帮助!
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
//noinspection GradleCompatible
implementation 'com.android.support:appcompat-v7:28.0.0'
implementation 'com.android.support:cardview-v7:28.0.0'
implementation 'me.dm7.barcodescanner:zxing:1.9'
implementation 'com.android.support:support-media-compat:28.0.0'
implementation 'com.android.support.constraint:constraint-layout:1.1.3'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'com.android.support.test:runner:1.0.2'
androidTestImplementation 'com.android.support.test.espresso:espresso-core:3.0.2'
}
答案 2 :(得分:0)
完善的Noispection或Gradle兼容或混合版本解决方案可能会导致运行时崩溃
Click here and solve your problem
只需手动添加有冲突的版本。
转到您的gradle脚本->在依赖项部分中构建gradle(Module:app)并实现有冲突的版本,以方便转到链接。
确保在实施过程中没有空间。
implementation 'com.android.support:support-media-compat:28.0.0'
implementation 'com.android.support:support-v4:28.0.0'
您可以点击链接。