Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

00-login-expo - Fails after authorising: TypeError: Cannot read property 'accessToken' of undefined. No Credentials were previously set. #186

Open
4 tasks done
winterstein opened this issue Aug 19, 2024 · 0 comments

Comments

@winterstein
Copy link

Checklist

  • I have looked into the Readme (Base/Hooks/Expo) and have not found a suitable solution or answer.
  • I have searched the issues and have not found a suitable solution or answer.
  • I have searched the Auth0 Community forums and have not found a suitable solution or answer.
  • I agree to the terms within the Auth0 Code of Conduct.

Description

After login, there's no access to the user info. The code outputs an error.

The first time, login goes through an authorisation process (e.g. auth via Google). It then returns to the app screen -- which still shows a Log In button.
There is also now an error message: No Credentials were previously set

Here is the log output from npx expo run:android:

Opening com.auth0samples://expo-development-client/?url=http%3A%2F%2F192.168.178.21%3A8081 on XQ_AS52
› Logs for your project will appear below. Press Ctrl+C to exit.
Android Bundling complete 831ms
LOG [TypeError: Cannot read property 'accessToken' of undefined]

This is with the code as downloaded from the Auth0 dashboard.

I have removed Expo Go from my phone to ensure that Expo Go is not being used. This is an expo development build.

Reproduction

  1. Download a version of 00-login-expo from the Auth0 dashboard, with the project settings in place.
  2. Follow the install instructions https://github.com/auth0-samples/auth0-react-native-sample/tree/master/00-Login-Expo
  3. Deploy to a local android phone
  4. Try to login...
  5. ...Stuck. The expo log says: LOG [TypeError: Cannot read property 'accessToken' of undefined]

The issue can be reproduced consistently.

Additional context

Computer: Linux Mint

npx expo --version
0.7.3

adb --version
Android Debug Bridge version 1.0.41
Version 35.0.1-11580240
Installed as /home/daniel/Android/Sdk/platform-tools/adb
Running on Linux 6.8.0-40-generic (x86_64)

Phone: Sony Xperia V, running Android v12

Sample

Expo

Platform

Android

Platform version(s)

12

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant