Skip to content

bug: Successive Calls to signInWithPhoneNumber or linkWithPhoneNumber Fail Without any Error Output #724

@howlettga

Description

@howlettga

Plugin(s)

  • Analytics
  • App
  • App Check
  • Authentication
  • Crashlytics
  • Cloud Firestore
  • Cloud Functions
  • Cloud Messaging
  • Cloud Storage
  • Performance
  • Remote Config

Version

6.1.0

Platform(s)

  • Android
  • iOS
  • Web

Current behavior

If I make successive calls to signInWithPhoneNumber or linkWithPhoneNumber using the same phone number, it silently fails. The PhoneVerificationFailedEvent event does not fire, neither does the PhoneCodeSentEvent.

If I wait some amount of time between calls, it succeeds. 30 second interval fails, 60 second interval succeeds.
iOS always succeeds without any interval.

Expected behavior

The PhoneCodeSentEvent event fires or the PhoneVerificationFailedEvent event fires.

Reproduction

https://github.com/robingenz/capacitor-firebase-authentication-demo

Steps to reproduce

  1. In an Android Device environment
  2. With standard configuration
  3. Run the signInWithPhoneNumber method successively to resend the verification text repeatedly
  4. Check for any event to fire.

Other information

This seems to be potentially a bug in the underlying firebase android sdk. I assume the verifyPhoneNumber implementation is pretty straightforward to bubble up events. I can try to submit a bug there instead if that's the case.

Capacitor doctor

$ npx cap doctor
💊 Capacitor Doctor 💊

Latest Dependencies:

@capacitor/cli: 6.1.2
@capacitor/core: 6.1.2
@capacitor/android: 6.1.2
@capacitor/ios: 6.1.2

Installed Dependencies:

@capacitor/cli: 6.1.1
@capacitor/core: 6.1.1
@capacitor/android: 6.1.2
@capacitor/ios: 6.1.2

[success] iOS looking great! 👌
[success] Android looking great! 👌

Before submitting

  • I have read and followed the bug report guidelines.
  • I have attached links to possibly related issues and discussions.
  • I understand that incomplete issues (e.g. without reproduction) are closed.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions