React-native-auth0: Android: Unable to enter email code when resuming application from launcher

Created on 9 Feb 2018  路  6Comments  路  Source: auth0/react-native-auth0

Issue

When using react-native-auth0 on Android to authenticate against an auth0 client using a passwordless email code a user is unable to enter their email code when resuming the application from the launcher or launching it from a home screen shortcut.

Steps to reproduce

  1. Download the auth0 sample app from https://auth0.com/docs/quickstart/native/react-native (my sample app was in a file named 00-login.zip)
  2. Open a terminal window and cd to the 00-login.zip location
  3. unzip 00-login
  4. cd 00-login
  5. npm install
  6. react-native run-android
  7. Click on the "Log In" button
  8. Enter email address and press "submit"
  9. Notice that auth0 lock is now requesting a code
  10. Press the Android HOME button
  11. Open email application on device to get the code
  12. Press the Android HOME button
  13. Open the application launcher
  14. Tap on the Auth0Sample app

Expected Behavior

I am shown the Enter a code custom tab

Actual Behavior

I am shown the original page with the Log In button

Example

auth0-example

Most helpful comment

RE: Thanks for the gif, please can you retest in a real browser such as Chrome or Firefox.

  • Testing with Chrome, Firefox, and Firefox Focus all show the same behavior on multiple devices, I will attach some gifs to this post shortly

RE: Does this still happens if you open the app from the "recents apps" instead of clicking the app icon in the drawer?

  • This does not happen when resuming the application from the "recent apps".
  • This does happen when:

    1. Tapping the app icon from the "Android Launcher" / app drawer

    2. Tapping the app icon from a shortcut added to the "home screen"

GIF

Real Browsers: Chrome and Firefox Focus

auth0-example-android-emulator

Real Browsers: Chrome and Firefox

auth0-example-genymotion

All 6 comments

Thanks for the gif, please can you retest in a real browser such as Chrome or Firefox.

Thanks for all the details 馃帀 . Does this still happens if you open the app from the "recents apps" instead of clicking the app icon in the drawer?

RE: Thanks for the gif, please can you retest in a real browser such as Chrome or Firefox.

  • Testing with Chrome, Firefox, and Firefox Focus all show the same behavior on multiple devices, I will attach some gifs to this post shortly

RE: Does this still happens if you open the app from the "recents apps" instead of clicking the app icon in the drawer?

  • This does not happen when resuming the application from the "recent apps".
  • This does happen when:

    1. Tapping the app icon from the "Android Launcher" / app drawer

    2. Tapping the app icon from a shortcut added to the "home screen"

GIF

Real Browsers: Chrome and Firefox Focus

auth0-example-android-emulator

Real Browsers: Chrome and Firefox

auth0-example-genymotion

I can confirm that this happens just as described above. Though it was not introduced in the latest PR https://github.com/auth0/react-native-auth0/pull/126 so this requires a bit more research on our side.

@seanpatrickcatlin if this is still happening, can you please confirm if you are or not using react native navigation library along with this one?

I will check if this still happens within the next day or 2.

This bug report specifically references that this happens with the sample project provided by auth0, so react native navigation was not used.

Was this page helpful?
0 / 5 - 0 ratings