2016-07-18 2 views
2

fabric.io에서 crashlytics를 사용하는 애플리케이션을 빌드하려고했습니다. 하지만 빌드는 위에서 언급 한 오류와 함께 실패합니다.피어가 인증되지 않음 : Android Studio에서 앱을 빌드하는 중 오류가 발생했습니다.

Executing tasks: [clean, :app:generateDebugSources, :app:generateDebugAndroidTestSources] 

Configuration on demand is an incubating feature. 

FAILURE: Build failed with an exception. 

* What went wrong: 
A problem occurred configuring project ':app'. 
> Could not resolve all dependencies for configuration ':app:classpath'. 
    > Could not resolve io.fabric.tools:gradle:1.+. 
    Required by: 
     TestProject18July2016:app:unspecified 
     > Could not resolve io.fabric.tools:gradle:1.+. 
     > Failed to list versions for io.fabric.tools:gradle. 
      > Unable to load Maven meta-data from https://maven.fabric.io/public/io/fabric/tools/gradle/maven-metadata.xml. 
       > Could not GET 'https://maven.fabric.io/public/io/fabric/tools/gradle/maven-metadata.xml'. 
        > peer not authenticated 

* Try: 
Run with --stacktrace option to get the stack trace. Run with --info or --debug option to get more log output. 

BUILD FAILED 

Total time: 1.367 secs 

인터넷이 프록시 서버 뒤에 있습니다. gradle.properties 파일에서 HTTP & HTTPS 설정을 사용하도록 설정했습니다.

## Project-wide Gradle settings. 
# 
# For more details on how to configure your build environment visit 
# http://www.gradle.org/docs/current/userguide/build_environment.html 
# 
# Specifies the JVM arguments used for the daemon process. 
# The setting is particularly useful for tweaking memory settings. 
# Default value: -Xmx10248m -XX:MaxPermSize=256m 
# org.gradle.jvmargs=-Xmx2048m -XX:MaxPermSize=512m -XX:+HeapDumpOnOutOfMemoryError -Dfile.encoding=UTF-8 
# 
# When configured, Gradle will run in incubating parallel mode. 
# This option should only be used with decoupled projects. More details, visit 
# http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 
# org.gradle.parallel=true 
#Mon Jul 18 11:14:57 IST 2016 
systemProp.http.proxyPassword=<PASSWORD> 
systemProp.https.proxyUser=<USERID> 
systemProp.https.proxyPort=<PORT> 
systemProp.http.proxyHost=<PROXY_SERVER_ADDRESS> 
systemProp.https.proxyPassword=<PASSWORD> 
systemProp.https.proxyHost=<PROXY_SERVER_ADDRESS> 
systemProp.http.proxyUser=<USERID> 
systemProp.http.proxyPort=<PORT> 

내 build.gradle 파일이 울부 짖는 소리입니다 :

// Top-level build file where you can add configuration options common to all sub-projects/modules. 

buildscript { 
    repositories { 
     jcenter() 
    } 
    dependencies { 
     classpath 'com.android.tools.build:gradle:1.5.0' 

     // NOTE: Do not place your application dependencies here; they belong 
     // in the individual module build.gradle files 
    } 
} 

allprojects { 
    repositories { 
     jcenter() 
    } 
} 

task clean(type: Delete) { 
    delete rootProject.buildDir 
} 

내 app.gradle 파일이 울부 짖는 소리입니다 : 나는 안드로이드 스튜디오 버전 1.5.1을 사용하고

현재
buildscript { 
    repositories { 
     maven { url 'https://maven.fabric.io/public' } 
    } 

    dependencies { 
     classpath 'io.fabric.tools:gradle:1.+' 
    } 
} 
apply plugin: 'com.android.application' 
apply plugin: 'io.fabric' 

repositories { 
    maven { url 'https://maven.fabric.io/public' } 
} 


android { 
    compileSdkVersion 23 
    buildToolsVersion "24.0.0" 

    defaultConfig { 
     applicationId "testfirebase.kishor.testproject18july2016" 
     minSdkVersion 19 
     targetSdkVersion 23 
     versionCode 1 
     versionName "1.0" 
    } 
    buildTypes { 
     release { 
      minifyEnabled false 
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 
     } 
    } 
} 

dependencies { 
    compile fileTree(dir: 'libs', include: ['*.jar']) 
    /* testCompile 'junit:junit:4.12'*/ 
    compile 'com.android.support:appcompat-v7:23.1.1' 
    compile 'com.android.support:design:23.1.1' 
    compile('com.crashlytics.sdk.android:crashlytics:[email protected]') { 
     transitive = true; 
    } 
} 

(2.1 시도 또한 행운은 없습니다.) Google을 많이 검색했지만 정확한 해결책을 찾을 수 없습니다.

친절히 도와주세요.

감사합니다.

답변

5

오랜 시간을 들여 해결 방법을 찾았습니다.

실제로 problemetic 받는다는 URL : https://maven.fabric.io/public/io/fabric/tools/gradle/maven-metadata.xml

이 URL을 노호하는 리디렉션 된 안드로이드 스튜디오에서 어떻게 든 https://s3.amazonaws.com/fabric-artifacts/public/io/fabric/tools/gradle/maven-metadata.xml

이 리디렉션이 실패했다. 그래서 build.gradle 응용 프로그램에서 maven URL을 바꿨습니다. 내 문제를 해결

maven { url 'http://s3.amazonaws.com/fabric-artifacts/public' } 

maven { url 'https://maven.fabric.io/public' } 

에서.

+0

이것은 나를 위해 일했습니다. 당신이 말한 변화없이 일하도록 할 수있는 기회? –

+0

@RahulTiwari, Nope. 나는 이것을위한 다른 해결책을 찾을 수 없었다. – krishna5688

+0

여전히 같은 오류 – SpyZip

관련 문제