didi / DoKit

一款面向泛前端产品研发全生命周期的效率平台。
Apache License 2.0
20.07k stars 3.09k forks source link

【DoKit生态场景】-库缺失 #1155

Open jannonx opened 8 months ago

jannonx commented 8 months ago

Cause 1: org.gradle.internal.resolve.ModuleVersionNotFoundException: Could not find com.android.volley:volley:1.1.1. Searched in the following locations:

==============================================================================

wanlinruo commented 6 months ago

处理方案:对于库(com.github.ybq:Android-SpinKit:1.4.0)可以添加 maven { setUrl("https://maven.google.com") },对于库(com.android.volley:volley:1.1.1)的1.1.1版本只在jcenter发布,但jcenter已过期,所以此处解决方案,暂时可以提高com.android.volley:volley的版本到1.2.0或者1.2.1即可,gradle的版本仲裁会取高版本,可以参考我的初始化代码如下:

pluginManagement {
    repositories {
        google()
        mavenCentral()
        maven { setUrl("https://jitpack.io") }
        gradlePluginPortal()
    }
}
dependencyResolutionManagement {
    repositoriesMode.set(RepositoriesMode.FAIL_ON_PROJECT_REPOS)
    repositories {
        google()
        mavenCentral()
        maven { setUrl("https://jitpack.io") }
    }
}
    // Dokit调试工具
    debugImplementation("io.github.didi.dokit:dokitx:3.7.1")
    releaseImplementation("io.github.didi.dokit:dokitx-no-op:3.7.1")
    debugImplementation("com.android.volley:volley:1.2.0")