provider/aws: aws_ami: handle deletion of AMIs (#9721)
provider/aws: aws_ami: handle deletion of AMIs (#9721)

Previously this resource (and, by extension, the aws_ami_copy and
aws_ami_from_instance resources that share much of its implementation)
was handling correctly the case where an AMI had been recently
deregistered, and was thus still returned from the API, but not correctly
dealing with the situation where the AMI has been removed altogether.

Now we additionally handle the NotFound error returned by the API when
we request a non-existent AMI, and remove the AMI from the state in the
same way we do for deregistered AMIs.
kjmkznr/terraform-provider-aws,charles-at-geospock/terraform-provider-aws,terraform-providers/terraform-provider-aws,nbaztec/terraform-provider-aws,charles-at-geospock/terraform-provider-aws,Ninir/terraform-provider-aws,ClementCunin/terraform-provider-aws,charles-at-geospock/terraform-provider-aws,ClementCunin/terraform-provider-aws,ClementCunin/terraform-provider-aws,ashinohara/terraform-provider-aws,nbaztec/terraform-provider-aws,kjmkznr/terraform-provider-aws,ClementCunin/terraform-provider-aws,Ninir/terraform-provider-aws,ashinohara/terraform-provider-aws,nbaztec/terraform-provider-aws,ashinohara/terraform-provider-aws,terraform-providers/terraform-provider-aws,charles-at-geospock/terraform-provider-aws,terraform-providers/terraform-provider-aws,Ninir/terraform-provider-aws,kjmkznr/terraform-provider-aws,Ninir/terraform-provider-aws,terraform-providers/terraform-provider-aws,kjmkznr/terraform-provider-aws,nbaztec/terraform-provider-aws,ashinohara/terraform-provider-aws