J'ai essayé d'utiliser la dernière version de Firebase pour Android dans mon fichier de classement. J'essaye de construire une authentification de numéro de téléphone firebase mais j'obtiens continuellement cette erreur, c'est parce que je n'ai pas pu trouver spécifiquement à mon problème:
Error:Execution failed for task ':app:processDebugManifest'.
> Manifest merger failed : Attribute meta-data#Android.support.VERSION@value value=(26.0.2) from [com.Android.support:design:26.0.2] AndroidManifest.xml:28:13-35
is also present at [com.Android.support:customtabs:26.0.1] AndroidManifest.xml:25:13-35 value=(26.0.1).
Suggestion: add 'tools:replace="Android:value"' to <meta-data> element at AndroidManifest.xml:26:9-28:38 to override.
Voici mon application: fichier gradle
apply plugin: 'com.Android.application'
Android {
compileSdkVersion 26
buildToolsVersion "26.0.1"
defaultConfig {
applicationId "com.shimetaapp.shimetacustomerapp"
minSdkVersion 21
targetSdkVersion 26
versionCode 1
versionName "1.0"
testInstrumentationRunner "Android.support.test.runner.AndroidJUnitRunner"
vectorDrawables.useSupportLibrary = true
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-Android.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
compile fileTree(dir: 'libs', include: ['*.jar'])
androidTestCompile('com.Android.support.test.espresso:espresso-core:2.2.2', {
exclude group: 'com.Android.support', module: 'support-annotations'
})
compile 'com.squareup.picasso:picasso:2.5.2'
compile 'com.squareup.retrofit2:retrofit:2.3.0'
compile 'com.squareup.retrofit2:converter-gson:2.3.0'
compile 'com.synnapps:carouselview:0.1.4'
compile 'com.astuetz:pagerslidingtabstrip:1.0.1'
compile 'com.Android.support:appcompat-v7:26.+'
compile 'com.Android.support:design:26.+'
compile 'de.hdodenhof:circleimageview:2.1.0'
compile 'com.Android.support.constraint:constraint-layout:1.0.0-alpha7'
compile 'com.Android.support:cardview-v7:26.+'
compile 'com.Android.support:recyclerview-v7:26.+'
compile 'com.Android.support:support-v4:26.+'
compile 'com.Android.support:support-vector-drawable:26.+'
// compile 'com.facebook.Android:account-kit-sdk:4.11.0'
// compile 'com.facebook.Android:facebook-Android-sdk:4.11.0'// Firebase Authentication
testCompile 'junit:junit:4.12'
// Firebase Database
compile 'com.google.firebase:firebase-auth:11.0.4'
compile 'com.google.firebase:firebase-messaging:11.0.4'
compile 'com.google.firebase:firebase-config:11.0.4'
compile 'com.firebaseui:firebase-ui-auth:2.3.0'
}
apply plugin: 'com.google.gms.google-services'
Voici mon fichier manifeste
<?xml version="1.0" encoding="utf-8"?>
<manifest xmlns:Android="http://schemas.Android.com/apk/res/Android"
package="com.shimetaapp.shimetacustomerapp">
<uses-permission Android:name="Android.permission.INTERNET" />
<uses-permission Android:name="Android.permission.READ_PHONE_STATE" />
<uses-permission Android:name="Android.permission.RECEIVE_SMS" />
<uses-permission Android:name="Android.permission.GET_ACCOUNTS" />
<uses-permission Android:name="Android.permission.READ_CONTACTS" />
<uses-permission Android:name="Android.permission.WRITE_CONTACTS" />
<uses-permission Android:name="Android.permission.MANAGE_ACCOUNTS" />
<uses-permission Android:name="Android.permission.READ_PROFILE" />
<application
Android:name=".activity.App"
Android:allowBackup="true"
Android:icon="@mipmap/ic_launcher"
Android:label="@string/app_name"
Android:roundIcon="@mipmap/ic_launcher_round"
Android:supportsRtl="true"
Android:theme="@style/AppTheme">
<activity
Android:name=".activity.MainActivity"
Android:theme="@style/AppTheme" />
<activity
Android:name=".activity.ProfileActivity"
Android:theme="@style/AppTheme.NoActionBar" />
<activity
Android:name=".activity.SettingsActivity"
Android:label="@string/title_activity_settings" />
<activity
Android:name=".activity.SplashActivity"
Android:theme="@style/AppTheme.NoActionBar">
<intent-filter>
<action Android:name="Android.intent.action.MAIN" />
<category Android:name="Android.intent.category.LAUNCHER" />
</intent-filter>
</activity>
<activity Android:name=".activity.Purchases" />
<activity Android:name=".activity.PhoneNumberAuthentication">
<intent-filter>
<action Android:name="Android.intent.action.MAIN"/>
<category Android:name="Android.intent.category.DEFAULT"/>
</intent-filter>
</activity>
</application>
This est la documentation que j'ai utilisée pour configurer ma base de feu dans mon studio Android.
Conflit de version entre l'artefact de support
com.Android.support:design:26.0.2
et com.Android.support:customtabs:26.0.1
Mettez à jour votre version firebase-auth
, firebase-auth a une dépendance de customtabs
qui est la version inférieure de 26.0.1
dans votre cas.
compile 'com.google.firebase:firebase-auth:11.2.0'
compile 'com.google.firebase:firebase-messaging:11.2.0'
compile 'com.google.firebase:firebase-config:11.2.0'
ajouter ce code au fichier Gradle
configurations.all {
resolutionStrategy.eachDependency { DependencyResolveDetails details ->
def requested = details.requested
if (requested.group == 'com.Android.support') {
if (!requested.name.startsWith("multidex")) {
details.useVersion '26.0.0'
}
}
}
}