Closed
Description
Description
#40197 documented the use case for a warning diagnostic on the aws_ami
data source to notify practitioners of certain cases when filtering criteria are missing. In v6.0.0
of the AWS provider, this warning diagnostic should be changed to an error diagnostic which can be suppressed by setting a new, optional argument ignore_missing_filter_error
(naming TBD).
Affected Resource(s) and/or Data Source(s)
aws_ami
Potential Terraform Configuration
# Example affected configuration
#
# - most_recent is true
# - owners is not set
# - there are no filters on owner-id or image-id
data "aws_ami" "test" {
most_recent = true
filter {
name = "architecture"
values = ["x86_64"]
}
filter {
name = "name"
values = ["ubuntu/images/hvm-ssd/ubuntu-focal-20.04-amd64-server-*"]
}
# This argument will allow the data source to continue to be used with
# the same filters prior to this change
ignore_missing_filter_error = true
}
References
Relates #40197
Relates #14158
Relates #25566
Relates #25521
Would you like to implement a fix?
Yes