Skip to content

Invalid error code have been thrown: kGIDSignInErrorCodeUnknown, but should be kGIDSignInErrorCodeCanceled #471

@Romick2005

Description

@Romick2005

Describe the bug
If user cancel google signIn process at latest step (confirming two previous steps), the lib throws error with OIDErrorCodeProgramCanceledAuthorizationFlow that is handled as kGIDSignInErrorCodeUnknown, but it should be the same as OIDErrorCodeUserCanceledAuthorizationFlow has: kGIDSignInErrorCodeCanceled (The user canceled the sign-in flow.)

Related with react-native-google-signin

To Reproduce
Steps to reproduce the behavior:

  1. Go to login with Google
  2. Tap on 'Continue' (step 1)
  3. Select google account and press 'Continue' (step 2)
  4. On the last step select 'Cancel'.
  5. See 'Unknown error in google sign in. (kGIDSignInErrorCodeUnknown access_denied)' error, but it should be 'The user canceled the sign-in flow. (kGIDSignInErrorCodeCanceled)'

Expected behavior
Expected to see 'The user canceled the sign-in flow' error, not 'Unknown error in google sign in'.

Screenshots
image

Environment

  • Device: iPhone XS
  • OS: macOS Sonoma 14.5
  • Browser: Chrome

Additional context
Normal google sign in.

Metadata

Metadata

Assignees

No one assigned

    Labels

    bugSomething isn't working

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions