Firebaseを導入しようとしていたのですが、このようなエラーが発生します。
Google Play Service と Google Repository は最新っぽいのですが…
パッケージ名のみ編集させていただいてます。
Gradleの同期でエラー発生
1エラー:(39, 13) Failed to resolve: com.google.firebase:firebase-perf:11.4.0
// 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:2.3.3' // NOTE: Do not place your application dependencies here; they belong // in the individual module build.gradle files classpath 'com.google.gms:google-services:3.0.0' classpath 'com.google.firebase:firebase-plugins:1.1.1' } } allprojects { repositories { jcenter() } } task clean(type: Delete) { delete rootProject.buildDir }
apply plugin: 'com.android.application' apply plugin: 'com.google.firebase.firebase-perf' android { compileSdkVersion 26 buildToolsVersion "26.0.1" defaultConfig { applicationId 'com.sample.application' minSdkVersion 21 targetSdkVersion 26 versionCode 1 versionName "1.0" testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner" } buildTypes { release { minifyEnabled false proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' } } productFlavors { } } dependencies { compile fileTree(include: ['*.jar'], dir: 'libs') androidTestCompile('com.android.support.test.espresso:espresso-core:2.2.2', { exclude group: 'com.android.support', module: 'support-annotations' }) // compile 'com.android.support:design:25.3.1' compile 'com.android.support:appcompat-v7:26.+' compile 'com.android.support.constraint:constraint-layout:1.0.2' compile 'com.google.code.gson:gson:2.7' compile 'com.neovisionaries:nv-websocket-client:2.3' compile 'com.google.firebase:firebase-messaging:10.0.1' compile 'com.google.firebase:firebase-core:10.0.1' compile 'com.google.firebase:firebase-ads:10.0.1' // compile 'com.google.firebase:firebase-ads:11.2.0' 11.2.0 を使おうとすると「Failed to resolve」発生。上の行の 10.0.1 だとOK compile 'com.google.firebase:firebase-crash:10.0.1' compile 'com.google.firebase:firebase-perf:11.4.0' // エラー発生箇所 testCompile 'junit:junit:4.12' } apply plugin: 'com.google.gms.google-services'
回答1件
あなたの回答
tips
プレビュー
バッドをするには、ログインかつ
こちらの条件を満たす必要があります。
2017/10/23 13:39
2017/10/23 13:54
2017/10/23 14:00