Could not download guava.jar (com.google.guava:guava:19.0)

Could not download guava.jar (com.google.guava:guava:19.0)

一般原因是Gradle版本和一些远程依赖版本不匹配,修改方法 升级依赖版本或者降级 Gradle

如:GreenDAO

GreenDAO 与gradle版本冲突引起到问题

   dependencies {
        classpath 'com.android.tools.build:gradle:3.5.1'
        classpath 'org.greenrobot:greendao-gradle-plugin:3.2.2' // add plugin
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }

修改方法GreenDAO 降级 3.2.0

   dependencies {
        classpath 'com.android.tools.build:gradle:3.5.1'
        classpath 'org.greenrobot:greendao-gradle-plugin:3.2.0' // add plugin
        // NOTE: Do not place your application dependencies here; they belong
        // in the individual module build.gradle files
    }

或者按照GreenDAO官网降级gradle

buildscript {
    repositories {
        jcenter()
        mavenCentral() // add repository
    }
    dependencies {
        classpath 'com.android.tools.build:gradle:3.1.1'
        classpath 'org.greenrobot:greendao-gradle-plugin:3.2.2' // add plugin
    }
}
发布了257 篇原创文章 · 获赞 136 · 访问量 107万+

猜你喜欢

转载自blog.csdn.net/wds1181977/article/details/102764170