Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Welcome To Ask or Share your Answers For Others

Categories

0 votes
536 views
in Technique[技术] by (71.8m points)

firebase - OTP not sent in release on Android device

Phone auth works on a physical iOS device in debug and release, but only in debug for a physical Android device.

I've tried multiple solutions including adding the SHA-1 and SHA-256 to Firestore and downloading the latest google-services file. I've also added "uses-permission android:name="android.permission.INTERNET" to my manifest file.

I've spent weeks on this issue and went so far as to pay for a coding session to see if they could figure it out. No luck. I think I'm missing a permission or something for release because it works until I run "flutter run --release" or upload it to the Google Play store.

Does anyone have any ideas on how I could fix this issue?

question from:https://stackoverflow.com/questions/65866699/otp-not-sent-in-release-on-android-device

与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome To Ask or Share your Answers For Others

1 Answer

0 votes
by (71.8m points)

Some solutions that can help you solve the problem:

  • After the process of repeating the same process, sending the code to the same phone number, Firebase will block for a whole day. Please take this point into account and you should use the trial system only in the debug stage.

  • In the release stage, you must add the SHA-1 issued by Google and it will work normally.

  • I had the same problem and discovered that the solution to this problem was not from the code that I wrote, the problem appeared in the telecom network distributors inside the country in which I found and I contacted them and the problem was already solved.


与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…
Welcome to OStack Knowledge Sharing Community for programmer and developer-Open, Learning and Share
Click Here to Ask a Question

2.1m questions

2.1m answers

60 comments

57.0k users

...