copilot-cli icon indicating copy to clipboard operation
copilot-cli copied to clipboard

Opaque errors - difficult to debug why operation was failing

Open GavinRay97 opened this issue 5 years ago • 5 comments

Would it be possible to surface the errors from the CloudFormation -> StackSets page when the CLI fails?

I got a notice "Operation XXX-XXX-XXX" failed, but wasn't sure what that meant or where to find it. I lucked into discovering the Stack Instances tab of the above page, and then under Status Reason there was this:

ResourceLogicalId:ECRRepomyrepo, ResourceType:AWS::ECR::Repository, ResourceStatusReason:Resource of type 'AWS::ECR::Repository' with identifier 'org/image-name already exists..

But the CLI only said this about it:

✘ Failed to link account xxxxxxxx and region us-east-1 to application appname.

✘ deploy env staging to application appname: adding new stack instance for environment staging: operation xxxxx-xxx-xxx-xxx-xxxx for stack set app-infrastructure failed

Just deleting the ECR repo and letting it create it again fixed it :+1:

GavinRay97 avatar Sep 08 '20 01:09 GavinRay97

Thanks yeah, this UX improvement totally makes sense!

efekarakus avatar Sep 08 '20 15:09 efekarakus

+1

janpoltan avatar Apr 21 '22 09:04 janpoltan

ran into this issue, and this helped me solve it. good candidate for documentation tag?

rmarops avatar Sep 20 '22 15:09 rmarops

@rmarops with which version of the CLI did you run into this issue? We recently released in 1.21.1 improvements for surfacing the stackset operation failure reason, I was wondering if this error case still missed in it.

efekarakus avatar Sep 20 '22 20:09 efekarakus

at the time the old 1.15 version -- i was in middle of reverting an app after having the grace period issues with 1.21.1

rmarops avatar Sep 20 '22 20:09 rmarops