未能解析:com.google.android.gms:play.services-vision



我正在尝试构建我的第一个android应用程序。所以在这个过程中,我遵循了一些旧的视频教程,并在这个过程中将我的工具版本搞砸了。当我试图将我的渐变与各种版本的同步时

com.google.android.gms:play.services-vision:

但每次都会失败。我也拿不到这本书的最新版本。我正在使用以下版本的Google Play服务:

compile 'com.google.android.gms:play.services-vision:11.6.0'

但它正在失败。我遗漏了什么吗?我的依赖项是:

dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'com.android.support:appcompat-v7:28.0.0-alpha3'
implementation 'com.android.support.constraint:constraint-layout:1.1.2'
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'
//Add lib
compile 'com.google.android.gms:play.services-vision:11.6.0'
}

遇到类似问题,请尝试添加maven{url"https://maven.google.com"}到项目级build.gradle(根gradle(中的存储库列表,如下所示。

allprojects {
repositories {
jcenter()
maven { url "https://maven.google.com" }
}
}

希望能有所帮助。

相关内容

最新更新