1. 程式人生 > >Android Studio 啟動 無緣故報 Error:Could not find common.jar

Android Studio 啟動 無緣故報 Error:Could not find common.jar

Error:Could not find common.jar (android.arch.core:common:1.0.0).

Searched in the following locations:https://jcenter.bintray.com/android/arch/core/common/1.0.0/common-1.0.0.jar

在昨天貌似很多人,突然間報出這個錯誤! 我也遇到了!!

怎麼解決這個坑呢?

親測可用!

如下:

把你專案不管是依賴底下的build還是專案app底下的build所有引用的support 全部改為統一版本 不要使用 ".+" 這種自動引用版本!!!!!!!!!!!

如:

compile 'com.android.support:appcompat-v7:26.+'
改成
compile 'com.android.support:appcompat-v7:26.0.0-alpha1'
可以試試把專案的build
allprojects {
    repositories {
        maven {url "https://maven.google.com"}
        jcenter()//放到google後面載入
        maven { url 'https://jitpack.io' }    
}
}