Closed howdyhyber closed 3 months ago
please provide the full stack trace of the error
Hi @howdyhyber ,
It's not clear what your production environment looks like.
Your code seems correct, and the fact that it works locally points to a potential problem with the environment itself.
Like @kuhe suggested, can you please share the full stack trace for the error and perhaps tell us more about the environment in which you are executing the SDK code?
Thanks, Ran~
I figured out what the problem is, I did not use @aws-sdk/credential-provider-cognito-identity because it is said in npm in its usage info, "You probably shouldn't, at least directly. Please use [@aws-sdk/credential-providers (https://www.npmjs.com/package/@aws-sdk/credential-providers) instead." I used @aws-sdk/credential-providers and it is perfectly working now.
This thread has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs and link to relevant comments in this thread.
Checkboxes for prior research
Describe the bug
I specified the region already, it works in local but it doesn't work in production.
SDK version number
"@aws-sdk/client-cognito-identity": "^3.549.0", "@aws-sdk/client-cognito-identity-provider": "^3.549.0", "@aws-sdk/credential-provider-cognito-identity": "^3.549.0"
Which JavaScript Runtime is this issue in?
Node.js
Details of the browser/Node.js/ReactNative version
v16.14.2
Reproduction Steps
Observed Behavior
Works when run locally, does not run in production
Expected Behavior
Based on the current code, it should work, the config is right
Possible Solution
No response
Additional Information/Context
No response