gpt4 book ai didi

java - 没有虚拟方法 verifyPhoneNumber,致命异常 : main

转载 作者:行者123 更新时间:2023-12-03 03:39:24 25 4
gpt4 key购买 nike

将库更新到 Gradle 文件后,我在尝试通过电话号码进行身份验证后遇到此错误。

--------- beginning of crash
2020-11-04 00:33:11.574 23042-23042/com.roko.hearth E/AndroidRuntime: FATAL EXCEPTION: main
Process: com.roko.hearth, PID: 23042
java.lang.NoSuchMethodError: No virtual method verifyPhoneNumber(Ljava/lang/String;JLjava/util/concurrent/TimeUnit;Ljava/util/concurrent/Executor;Lcom/google/firebase/auth/PhoneAuthProvider$OnVerificationStateChangedCallbacks;Lcom/google/firebase/auth/PhoneAuthProvider$ForceResendingToken;)V in class Lcom/google/firebase/auth/PhoneAuthProvider; or its super classes (declaration of 'com.google.firebase.auth.PhoneAuthProvider' appears in /data/app/com.roko.hearth-BB3VSAScHPWVlEGN0MD3dw==/base.apk!classes2.dex)
at com.firebase.ui.auth.ui.phone.PhoneNumberVerificationHandler.verifyPhoneNumber(PhoneNumberVerificationHandler.java:32)
at com.firebase.ui.auth.ui.phone.CheckPhoneNumberFragment.onNext(CheckPhoneNumberFragment.java:164)
at com.firebase.ui.auth.ui.phone.CheckPhoneNumberFragment.onClick(CheckPhoneNumberFragment.java:140)
at android.view.View.performClick(View.java:7140)
at com.google.android.material.button.MaterialButton.performClick(MaterialButton.java:992)
at android.view.View.performClickInternal(View.java:7117)
at android.view.View.access$3500(View.java:801)
at android.view.View$PerformClick.run(View.java:27351)
at android.os.Handler.handleCallback(Handler.java:883)
at android.os.Handler.dispatchMessage(Handler.java:100)
at android.os.Looper.loop(Looper.java:214)
at android.app.ActivityThread.main(ActivityThread.java:7356)
at java.lang.reflect.Method.invoke(Native Method)
at com.android.internal.os.RuntimeInit$MethodAndArgsCaller.run(RuntimeInit.java:492)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:930)
我搜索了一个解决方案,但同样的问题
我将这些用于 Firebase 的库放入 Gradle
// Firebase
implementation platform('com.google.firebase:firebase-bom:26.0.0')
//Firebase Authentication
implementation 'com.google.firebase:firebase-auth'
implementation 'com.firebaseui:firebase-ui-auth:6.2.1'

//Firebase Database
implementation 'com.google.firebase:firebase-database'
implementation 'com.firebaseui:firebase-ui-database:6.2.1'

//Firebase Messaging
implementation 'com.google.firebase:firebase-messaging'

//Firebase Storage
implementation 'com.google.firebase:firebase-storage'

implementation 'com.google.firebase:firebase-perf'

implementation 'com.google.firebase:firebase-core'

/////////////////////////////////////////////////////////////////////////////
并且 SHA-1 代码是相同的。有人可以帮忙吗?

最佳答案

implementation platform('com.google.firebase:firebase-bom:26.1.0')
implementation 'com.google.firebase:firebase-auth'
implementation 'com.firebaseui:firebase-ui-auth:7.0.0'
这是真正的修正 ;)

关于java - 没有虚拟方法 verifyPhoneNumber,致命异常 : main,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/64672343/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com