0

実行デバッグボタンが無効になっています。 私はこれについて多くの回答を見ましたが、私の場合は解決策が正しくありません。 これは私のGradleコンソールの私のエラーです:依存のHTTPClient - 私の<strong>Androidのメーカー</strong>でAndroidStudio

WARNING: Dependency org.apache.httpcomponents:httpclient:4.0.1 is ignored for debug as it may be conflicting with the internal version provided by Android. 
     In case of problem, please repackage it with jarjar to change the class packages 
WARNING: Dependency org.apache.httpcomponents:httpclient:4.0.1 is ignored for release as it may be conflicting with the internal version provided by Android. 
     In case of problem, please repackage it with jarjar to change the class packages 
Incremental java compilation is an incubating feature. 

これは私のbuild.gradleです:

apply plugin: 'com.android.application' 

android { 
    compileSdkVersion 24 
    buildToolsVersion "23.0.2" 

    defaultConfig { 
     applicationId "myProjectPackageName" 
     minSdkVersion 15 
     targetSdkVersion 24 
     versionCode 1 
     versionName "1.0" 
    } 
    buildTypes { 
     release { 
      minifyEnabled false 
      proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 
     } 
    } 
} 

repositories { 
    mavenCentral() 
    maven { 
     url "https://raw.github.com/embarkmobile/zxing-android-minimal/mvn-repo/maven-repository/" 
    } 
    maven { url "https://jitpack.io" } 
} 

dependencies { 
    compile fileTree(dir: 'libs', include: ['*.jar']) 
    compile 'com.android.support:appcompat-v7:24.2.0' 

    // Zxing libraries Scan 
    compile 'com.embarkmobile:zxing-android-minimal:[email protected]' 
    compile 'com.embarkmobile:zxing-android-integration:[email protected]' 
    compile 'com.google.zxing:core:3.0.1' 

    //Google api books 
    compile 'com.google.apis:google-api-services-books:v1-rev80-1.21.0' 
    compile 'com.google.android.gms:play-services-appindexing:9.4.0' 

    // Dependency for Google Sign-In 
    compile 'com.google.android.gms:play-services-plus:9.4.0' 
    compile 'com.google.android.gms:play-services-auth:9.4.0' 

    //Facebook Login 
    compile 'com.facebook.android:facebook-android-sdk:4.13.2' 

    // Dependency for Firebase 
    compile 'com.google.firebase:firebase-messaging:9.4.0' 
    compile 'com.google.firebase:firebase-database:9.4.0' 
    compile 'com.google.firebase:firebase-storage:9.4.0' 
    compile 'com.github.bumptech.glide:glide:3.7.0' 


} 



dependencies { 
    compile 'com.android.support.constraint:constraint-layout:1.0.0-alpha4' 
} 
apply plugin: 'com.google.gms.google-services' 

あなたはdependenciesbuild.gradle内のファイルを除外するために必要な支援

+0

'http-client'に依存関係を追加しましたか? –

+0

いいえ、私はokhttpclientを削除しました。しかし、私はそれを使用しなかった – Carlo

答えて

2

のおかげで多くのことを。

compile('com.google.apis:google-api-services-books:v1-rev80-1.21.0') { 
    exclude module: 'httpclient' 
    exclude group: 'org.apache.httpcomponents' 
    exclude group: 'org.apache.httpcomponents', module: 'httpclient' 
} 

すべての設定から除外してください。

configurations { 
    compile.exclude group: "org.apache.httpcomponents", module: "httpclient" 
} 

スタジオを再起動してから、もう一度確認してください。または、Runボタンの横にあるドロップダウンメニューからappモジュールを選択します。

+0

これは再び同じ問題です。しかし、現在では、「ApplicationTest.javaは廃止予定のAPIを使用または無効にします。 注:詳細については、-Xlint:deprecationを使用して再コンパイルしてください。 – Carlo

+0

@Carlo上記の 'gradle'を更新してください。私の編集をチェックしてください。 –

+0

エラーはありませんが、実行ボタンとデバッグボタンはまだ無効になっています。 – Carlo

関連する問題