3
我正嘗試構建導入的項目。Android Studio:Gradle無法解決依賴問題
過程「搖籃:解決依賴‘:應用程序:_debugCompile’」只是繼續運行
於是我在網上搜索,發現我需要運行gradlew建立--stacktrace --debug在終端
然後,我看到,在某些時候Android Studio中試圖做到這一點:
Connecting to 10.153.20.12:8080
然後連接失敗,構建失敗過:
FAILURE: Build failed with an exception.
* What went wrong:
A problem occurred configuring root project 'MyProject'.
> Could not resolve all dependencies for configuration ':classpath'.
> Could not resolve com.android.tools.build:gradle:1.2.3.
Required by:
:MyProject:unspecified
> Could not resolve com.android.tools.build:gradle:1.2.3.
> Could not get resource 'https://jcenter.bintray.com/com/android/tools/build/gradle/1.2.3/gradle-1.2.3.pom'.
> Could not GET 'https://jcenter.bintray.com/com/android/tools/build/gradle/1.2.3/gradle-1.2.3.pom'.
> Connection to http://10.153.20.12:8080 refused
PS:其他項目的建設沒有問題
PPS:同樣的事情發生在不同的計算機
這裏是我的應用程序:文件的build.gradle:
apply plugin: 'com.android.application'
android {
compileSdkVersion 22
buildToolsVersion "22.0.1"
defaultConfig {
applicationId "ru.myrunner.myrunner"
minSdkVersion 15
targetSdkVersion 22
versionCode 1
versionName "1.0"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
compile 'com.pkmmte.view:circularimageview:1.1'
compile 'com.android.support:appcompat-v7:22.2.1'
compile 'com.android.support:cardview-v7:22.2.1'
compile 'com.google.android.gms:play-services:7.8.0'
compile 'com.android.support:recyclerview-v7:22.2.1'
}
編輯:顯然,問題是與
compile 'com.pkmmte.view:circularimageview:1.1'
您可以發佈Gradle代碼來聲明您的位置1.任何遠程回購2.您的項目的依賴關係? – Jolta
@Jolta更新。這不是我的項目,但我需要處理它 –
機器是否連接到互聯網?在我看來,錯誤消息中的URL是有效的:(https://jcenter.bintray.com/com/android/tools/build/gradle/1.2.3/gradle-1.2.3.pom) – Jolta