Android Question Firebase Auth doesn't work from Google Play

jvrh_1

Active Member
Licensed User
Hello, I have a problem.
When I compile and execute my app using the apk of my computer using Tools--B4Bridge--Connect... the app works fine and autentification with Google perfectly using Firebase Auth. But, when I install the same version of my apk from Google Play, the app don´t autentifcate. Any idea?
Atached the error message. Help me please. The app is in the Google Play in productive mode. I do not know why it happens
 

Attachments

  • ERROR.png
    ERROR.png
    11.4 KB · Views: 166
  • ERRO UNFILTER.png
    ERRO UNFILTER.png
    29.1 KB · Views: 153

jvrh_1

Active Member
Licensed User
I just get de username and name of the Google Account. Then I will use it in my app. I have made an example and works perfectly, but when I upload this one to Google Play and install the app from Google Play, the application doesn't work. Any idea?

B4X:
Sub Process_Globals
    'These global variables will be declared once when the application starts.
    'These variables can be accessed from all modules.
    Private auth As FirebaseAuth 'PARA REGISTRARME CON GOOGLE
End Sub

Sub Globals
    'These global variables will be redeclared each time the activity is created.
    'These variables can only be accessed from this module.
    Dim IMGACCEDER As ImageView
    Dim aliasgoogle, usuariogoogle As String
    Dim GOOGLEINICIALIZADO As Boolean
    GOOGLEINICIALIZADO=False
End Sub

Sub Activity_Create(FirstTime As Boolean)
    'Do not forget to load the layout file created with the visual designer. For example:
    'Activity.LoadLayout("Layout1")

    CREAR_INTERFAZ

End Sub

Sub Activity_Resume
    
End Sub

Sub Activity_Pause (UserClosed As Boolean)

End Sub
Sub CREAR_INTERFAZ
    
    IMGACCEDER.Initialize("IMGACCEDER")
    Activity.AddView(IMGACCEDER,(Activity.Width/2)-100dip,(Activity.Height/2)-100dip,200dip,200dip)
    IMGACCEDER.Bitmap=LoadBitmapResize(File.DirAssets,"CONECTAR.png",100%x,100%y,True)
    IMGACCEDER.gravity=Gravity.fill
    
End Sub
Sub Auth_SignedIn (User As FirebaseUser)
    Log("SignedIn: " & User.DisplayName)
    aliasgoogle=User.DisplayName.ToUpperCase
    usuariogoogle=User.Email.ToUpperCase
    Log ("Alias: " & aliasgoogle & " usuario: " & usuariogoogle)
    Msgbox(aliasgoogle & "  " & usuariogoogle,"Datos")
End Sub
Sub IMGACCEDER_CLICK
        If GOOGLEINICIALIZADO=False Then
            auth.Initialize("auth")
        End If
        If auth.CurrentUser.IsInitialized Then
            auth.SignOutFromGoogle
        End If
        auth.SignInWithGoogle
End Sub

Sub Activity_KeyPress (KeyCode As Int) As Boolean
    
End Sub
 
Upvote 0

jvrh_1

Active Member
Licensed User
Filter mode:
B4X:
0
SignInWithGoogle called
onAuthStateChanged: com.google.firebase.auth.internal.zzl@7c81993
** Activity (user_no_registrado) Pause, UserClosed = false **
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
SignInWithGoogle.ResultArrived
ResultArrived Error: Status{statusCode=DEVELOPER_ERROR, resolution=null}, null
** Activity (user_no_registrado) Resume **

Unfilter mode:
B4X:
endAllActiveAnimators on 0x7d4d594f00 (AlertController$RecycleListView) with handle 0x7d4edced60
0
SignInWithGoogle called
Timeline: Activity_launch_request time:226404 intent:Intent { act=com.google.android.gms.auth.GOOGLE_SIGN_IN pkg=xxxxxxxxxxx.com cmp=xxxxxxxx.com/com.google.android.gms.auth.api.signin.internal.SignInHubActivity (has extras) }
** Activity (user_no_registrado) Pause, UserClosed = false **
handleWindowVisibility: no activity for token android.os.BinderProxy@19da88
Timeline: Activity_launch_request time:226456 intent:Intent { act=com.google.android.gms.auth.GOOGLE_SIGN_IN pkg=com.google.android.gms (has extras) }
sending message to waiting queue (OnActivityResult)
running waiting messages (1)
SignInWithGoogle.ResultArrived
ResultArrived Error: Status{statusCode=DEVELOPER_ERROR, resolution=null}, null
** Activity (user_no_registrado) Resume **
 
Upvote 0

jvrh_1

Active Member
Licensed User
The app works fine when I install the .apk of my computer or using B4A --- B4a Bridge -- Connect in realase and Debug mode. But when I upload the app to Google Play and install from there, It doesn't work. The Sub "Auth_SignedIn (User As FirebaseUser)" event dont raise.
Please, help.
 
Upvote 0

jvrh_1

Active Member
Licensed User
Any idea? The app is in Productive Mode in Google Play. I have follow all the steps of the firebase turorial. My apk works on diferents devices and differents networks, and is the same version that I uploaded on Google Play, but if I install It from there does not work.
I do not know if is a configuration problem of my firebase console or my Google Play console.
 
Upvote 0

Computersmith64

Well-Known Member
Licensed User
Longtime User
When you released the app on Google Play did you use Google App Signing?

- Colin.
 
Upvote 0

Computersmith64

Well-Known Member
Licensed User
Longtime User
When you released the app on Google Play did you use Google App Signing?

- Colin.
OK - so you probably need to go to the Firebase console & update the SHA-1 signature with the one from the Play Store app signing. This link might help you...

- Colin.
 
Last edited:
Upvote 0
Top