AWS Amplify - There was an error initializing your environment - How to fix

AWS Amplify - There was an error initializing your environment - How to fix

AWS Amplify troubleshooting. Pulling a project down to a vanilla machine

Kirk Ryan · 1 minute read

So, the time has come to pull your amplify project down to another development machine and you've run into the dreaded "There was an error intializing your environment" error, possibly with a sidenote about team-provider-info.json does not exist.

Well fret no longer, this is an easy fix.

First, ensure you have the latest amplify cli installed. This can be done with the following command:

npm i -g @aws-amplify/cli

Next, once you have run an npm install or yarn on your newly cloned repo, run the following command:

 amplify configure project

Select "AWS Profile Setting" from the CLI options

When prompted "Do you want to update or remove the project level AWS profile?" select "update".

Select your credentials, in my case I used my AWS Profile on my localhost.

That's it - you can now successfully run a full pull from amplify.

amplify pull

I'll probably end up googling this in 2 years time and arriving back at my own article.

aws
amplify
ci-cd