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
Auth SignUp auto send another request and throw Error: No credentials, applicationId or region #3484
Comments
After trying and creating some new project, I notice that every new project got this issues:
I thought there are some changes in Amplify JS ? |
Run into same problem with new project |
Same here. Starting to get this today from the ng e2e, which tests Auth signin workflow. ( I was fine just yesterday) while deployed project is working fine. Very strange. |
Here is what I found so far. ( in my case) As soon as I disabled Analytics in my project, it works fine without the error. I agree the app may works fine for you, but it is not passing my ng e2e testing with that exception. The fact that there is no code change in my project. I believe it is a change on AWS Pinpoint REST API, combined with obviously, uncaught exception, and caching of credential in my old projects. |
@namnh06 Can you provide a copy of your |
I get same error with aws-amplify@unstable. Also happens with Auth.signIn() |
I found the conditions that is causing the AWSPintpointProvider.ts error. IF I import Analytics from '@aws-amplify/analytics'; even if I don't use it at runtime ( in our project we call analytics.record only in production mode set by environment.prod.ts ) THEN the Uncaught exception will appear. The exception start to appear today, an is likely because we upgraded to the latest amplify (stable) sometime this week. versions details ( everything are the latest stable except TypeScript is at 3.4.5) Angular 8.0.3 |
My aws-exports.js file is
Should there be generated I kind of remember that there used to be... Also tried adding Auth with default configuration and custom configuration |
Hi @sammartinez ,
for the whole package.json, you can look at it here: https://gist.github.com/namnh06/336b49acac9edefc4df152a6b3024c46 I tried to remove everything & install aws-amplify with the version like the old one but no luck.
Tried it, no luck either. I thought @gerrytsui was right and wrong, because of if API, so, the old project should be affect too, but there is not. |
I get the same error with react native after an update. |
I had posted a question regarding the same: https://stackoverflow.com/questions/56680112/bad-request-is-returned-when-amplify-is-configured-for-hosted-ui-in-angular-6 |
@arjunsk I got one from yesterday, but no luck till now : https://stackoverflow.com/questions/56659183/amplify-auth-signup-auto-send-another-request-and-throw-error-no-credentials-a |
I got it working by reverting
|
Can confirm that this works. Thanks! |
I'm experiencing the same issue but I'm not using |
Are you sure you have not imported the whole aws-amplify package? |
@filipemcg oh oh oh. Thanks for the tip! using only |
we are not using analytics, but updating all imports like the following [no aws-amplify] solved the issue ..
|
Disabling as per the docs fixed this for me. |
#3614 should prevent "Error: No credentials, applicationId or region." from occurring when Analytics is not be used or configured. |
This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Thank you for your contributions. |
This issue has been automatically closed because of inactivity. Please open a new issue if are still encountering problems. |
Thanks, this worked! You can also suppress the warning if disabling analytics doesn't fix the issue: YellowBox.ignoreWarnings(["No credentials, applicationId or region"]); |
I am also facing this issue now. Note: I am not using analytics anywhere while Auth.signIn and Auth.signUp
|
In your configs:
|
Above solutions not worked for me I am using aws-amplify and aws-amplify-react-native |
The following solution is working for me. Have to manually disable Analytics when using with React Native:
|
This is still an issue, disabling the analytics is not the right solution. Are there any status updates on this? Did anyone figure out what's causing it |
This issue has been automatically locked since there hasn't been any recent activity after it was closed. Please open a new issue for related bugs. Looking for a help forum? We recommend joining the Amplify Community Discord server |
** Which Category is your question related to? **
Auth
** What AWS Services are you utilizing? **
Cognito
** Provide additional details e.g. code snippets **
I have 2 projects which are using the same code like this:
Auth.signUp({ username, password, attributes }).then(data => console.log(data)).catch(error => console.log(error)).finally(() => console.log('done'));
Just like this: https://aws-amplify.github.io/docs/js/authentication#sign-up
Here is the problem show out:
https://cognito-idp.ap-southeast-2.amazonaws.com/
And : https://cognito-identity.ap-southeast-2.amazonaws.com/ which is after the first one and its response is :
After that, I got the error in console: Error: No credentials, applicationId or region.
Not sure why is the old project is working fine but with this one, this error show up. Is it because the different in amplify ?
Thanks.
The text was updated successfully, but these errors were encountered: