Skip to content

Make error message more verbose. #888

Open
@dmitry-mukhin

Description

@dmitry-mukhin

Terraform Version

# Copy-paste output from `terraform -v`
Terraform v1.9.7
on linux_amd64
+ provider registry.terraform.io/fastly/fastly v5.12.0

Affected Fastly Terraform Resource(s)

Please list the affected resources, for example:

  • fastly_tls_subscription

Terraform Configuration Files

# Copy-paste your Terraform configuration here.
resource "fastly_tls_subscription" "tls" {
  domains               = [for domain in var.tls_domains : domain]
  certificate_authority = var.certificate_authority
}

Expected Behavior

We have a lot of services.
I'm expecting to see more verbose error message when something like this occurs, so I can see that subscription(s) and what domain(s) cause the problem.

Actual Behavior

I see a bunch of errors that indicate what happend but not to which resources.

Debug Output (optional)

│ Error: 400 - Bad Request:
│ 
│     Title:  Can't delete subscription
│     Detail: Subscription has active domains
│ 
│ 
╵
╷
│ Error: 400 - Bad Request:
│ 
│     Title:  Can't delete subscription
│     Detail: Subscription has active domains
│ 
│ 
╵
╷
│ Error: 400 - Bad Request:
│ 
│     Title:  Can't delete subscription
│     Detail: Subscription has active domains
│ 
│ 
...

Steps to Reproduce

  1. remove some subsctriptions from the configuration
  2. run terraform apply

Important Factoids (optional)

We're running 100s of services.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions