amplify-js: Auth.currentAuthenticatedUser() Not Returning or Throwing a Catchable Error
Do you want to request a feature or report a bug? bug
What is the current behavior? Auth.currentAuthenticatedUser() does not resolve nor does it throw a catchable error.
If the current behavior is a bug, please provide the steps to reproduce and if possible a minimal demo of the problem. Your bug will get fixed much faster if we can run your code and it doesn’t have dependencies other than AWS Amplify.
In a React Native application built using Expo I have the following code (debugger statements inserted to confirm execution location).
debugger; Auth.currentAuthenticatedUser() .then(res => { debugger; console.log(‘current user info: \n’, res); }) .catch(err => { debugger; console.log(err); });
Only the first debugger statement which is prior to execution is reached. Additionally, nothing is logged to the console.
This code is called after a successfully using Auth.signIn() which returns the following CognitoUser object:

What is the expected behavior? If there is an error, I expect to receive something that I can catch
Which versions of Amplify, and which browser / OS are affected by this issue? Did this work in previous versions?
“aws-amplify”: “^0.4.4”, “aws-amplify-react-native”: “^0.2.15”, “expo”: “^27.0.0”,
You can turn on the debug mode to provide more info for us by setting window.LOG_LEVEL = 'DEBUG'; in your app.
About this issue
- Original URL
- State: closed
- Created 6 years ago
- Comments: 16 (5 by maintainers)
what was the outcome of this?
@powerful23 Thanks. Do you know when a version of aws-amplify will get published with your PR now that it’s been merged?
@reggie3 can you open the debug mode to check what happened when that function was called?