I integrated pinpoint analytics into one of our Android apps. (by following the GettingStarted guide [https://aws-amplify.github.io/docs/android/start] ). I added a few events and they got submitted successfully to pinpoint console after deploying this app. to an Android Phone.
So i committed the changes and asked a teammate to try this out. When he built the app. and ran it, it crashed with the following error:
*java.lang.RuntimeException: Failed to read awsconfiguration.json please check that it is correctly formed*
I was hoping that after committing the amplify files along with the .gitignore suggestions by amplify , the amplify environment and authentication details would get saved , but it doesn't seem so as the code looks for an awsconfiguration.json file but that isn't committed due to .gitignore changes by amplify.
What am i missing here? I am sharing a list of the amplify files that got committed and .gitignore updates below:
Amplify files that got committed:
amplify/.config/project-config.json
amplify/backend/analytics/helixandroid/parameters.json
amplify/backend/analytics/helixandroid/pinpoint-cloudformation-template.json
amplify/backend/auth/cognito*/*-cloudformation-template.yml
amplify/backend/auth/cognito*/parameters.json
amplify/backend/backend-config.json
amplify/team-provider-info.json
Amplify additions to my .gitignore file.
#amplify
amplify/\#current-cloud-backend
amplify/.config/local-*
amplify/backend/amplify-meta.json
amplify/backend/awscloudformation
build/
dist/
node_modules/
aws-exports.js
awsconfiguration.json