Registration returns 'Error: Amplify has not been configured correctly'
This is a little different from #1 although the symptom is the same.
In my case, the problem seemed to be that cdk-exports-dev.json was not updated by the back end configuring. It still had your eu-central-1 values as in GitHub so the amplify Auth class got pretty confused. When I manually populated the cdk-exports-dev.json values as cdk had created them in my account, everything worked. All good.
Is there a step missing in the instructions? Thanks.
PS - If you connect your buymeacoffee to PayPal, I'll buy you a bunch of coffees. This example probably saved me a lot of time.
Thank you for the issue.
Maybe I should delete the cdk-exports-dev.json file then.
I would have expected the values to be overwritten once a successful deployment is executed, but apparently not 🤷♂️
Heh, thank you, my BMC page is connected to Paypal, you don't have to though
Hmm. I didn't get the option of PayPal when I tried to buy you coffees. Only Credit Card. I try to limit my exposure by using PayPal where possible :-)
On the "I would have expected the values to be overwritten once a successful deployment is executed", I have a little more info now. Very mysterious to me. On the machine I did this on, I didn't have cdk installed (inadvertent, not on purpose). Somehow 'npm run cdk-create-stack' actually deployed the resources and seems to have done everything correctly except for overwriting the values. No idea where it got the cdk app to do this :-) Anyway I just retried the example on another machine that did have the cdk app installed (globally) and it overwrote the cdk-exports-dev.json with the right values. Haven't tested the result yet but I expect it will work fine too.
I deleted the cdk-exports-dev.json file from the repository, there's no good reason to keep my values from an old deployment there.
I must've missed it initially. I can't see a good reason why the values wouldn't get overwritten on successful deployment, but with Amplify and Cognito it's best to just roll with the punches and not overthink things.
Good idea. Thanks a lot for replying to this so quickly. Please close it.