Summary:
When attempting to amplify push
changes to my graphql api via the Amplify CLI after aborting an amplify push
(using ctrl-c) the cli complains that there is a deployment in progress and cannot deploy.
First error message:
A deployment is in progress.
If the prior rollback was aborted, run:
`amplify push --iterative-rollback` to rollback the prior deployment
`amplify push --force` to re-deploy
Both of those suggested commands result in:
✖ An error occurred when pushing the resources to the cloud
Cannot iteratively rollback as the following step does not contain a previousMetaKey: {"status":"WAITING_FOR_DEPLOYMENT"}
An error occurred during the push operation: Cannot iteratively rollback as the following step does not contain a previousMetaKey: {"status":"WAITING_FOR_DEPLOYMENT"}
All deployments in the Amplify Admin UI show as completed.
I tried amplify pull
, amplify env pull
, amplify pull --restore
(all of which override your local changes - heads up). None worked to solve my problem. Still could not amplify push
.
I finally found this idea: https://github.com/aws-amplify/amplify-adminui/issues/172#issuecomment-819784558
Solution
Deleting the deployment-state.json
file as suggested in that reply allowed me to perform amplify push
again. If you open it up you'll see that this is where the cli must be seeing the {"status":"WAITING_FOR_DEPLOYMENT"}
Sharing my solution here in case someone else has the same problem!
Solution
Deleting the deployment-state.json
file as suggested in that reply allowed me to perform amplify push again. If you open it up you'll see that this is where the cli must be seeing the {"status":"WAITING_FOR_DEPLOYMENT"}
.
Sharing my solution here in case someone else has the same problem!
Open the corresponding s3 bucket to the Amplify app.. usually begins with "Amplify-appname...." and delete the "deployment-state.json" file
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With