Я использую Firebase для разработки приложения для живого чата с Android, но после входа в систему возникают проблемы. После установки приложения оно запрашивает вход, а после входа показывает исключение. Пожалуйста, найдите код для моего файла build.gradle.
apply plugin: 'com.android.application'
apply plugin: 'com.google.gms.google-services'
android {
compileSdkVersion 28
defaultConfig {
applicationId "com.spitechchat"
minSdkVersion 17
targetSdkVersion 28
versionCode 1
versionName "1.0"
testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner"
}
buildTypes {
release {
minifyEnabled false
proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro'
}
}
}
dependencies {
implementation fileTree(dir: 'libs', include: ['*.jar'])
implementation 'androidx.appcompat:appcompat:1.1.0'
implementation 'androidx.constraintlayout:constraintlayout:1.1.3'
implementation 'com.firebaseui:firebase-ui:0.6.0'
implementation 'com.google.firebase:firebase-core:17.2.1'
implementation 'com.google.firebase:firebase-storage:19.1.0'
implementation 'com.google.firebase:firebase-database:19.2.0'
implementation 'com.google.firebase:firebase-auth:19.1.0'
//implementation 'com.google.android.gms:play-services- auth:16.0.0'
implementation 'com.google.android.gms:play-services-auth:17.0.0'
testImplementation 'junit:junit:4.12'
androidTestImplementation 'androidx.test.ext:junit:1.1.1'
androidTestImplementation 'androidx.test.espresso:espresso- core:3.2.0'
implementation 'com.google.android.material:material:1.0.0'
}
---------------------------------- ОШИБКА ----------------
2019-10-30 02:17:51.242 12860-12860/com.spitechchat E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.spitechchat, PID: 12860
java.lang.NoSuchMethodError: No virtual method fetchProvidersForEmail(Ljava/lang/String;)Lcom/google/android/gms/tasks/Task; in class Lcom/google/firebase/auth/FirebaseAuth; or its super classes (declaration of 'com.google.firebase.auth.FirebaseAuth' appears in /data/app/com.spitechchat-6-cb1cIi2aiGaaEHST0YfQ==/base.apk)
at com.firebase.ui.auth.ui.AcquireEmailHelper.checkAccountExists(AcquireEmailHelper.java:55)
at com.firebase.ui.auth.ui.email.EmailHintContainerActivity.onActivityResult(EmailHintContainerActivity.java:70)
at android.app.Activity.dispatchActivityResult(Activity.java:7433)
at android.app.ActivityThread.deliverResults(ActivityThread.java:4411)
at android.app.ActivityThread.handleSendResult(ActivityThread.java:4459)
at android.app.ActivityThread.-wrap19(Unknown Source:0)
at android.app.ActivityThread$H.handleMessage(ActivityThread.java:1738)
at android.os.Handler.dispatchMessage(Handler.java:106)
at android.os.Looper.loop(Looper.java:192)
at android.app.ActivityThread.main(ActivityThread.java:6753)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:550)at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:828)
2019-10-30 02: 17: 51.274 12860-12860 / com.spitechchat I / Process: Отправка сигнала. PID: 12860 SIG: 9