Skip to content

Permadiff on google_cloud_quotas_quota_preference when configure the 'preferred_value' to "0" #24480

@ruben-ferreira-external

Description

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request.
  • Please do not leave +1 or me too comments, they generate extra noise for issue followers and do not help prioritize the request.
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment.
  • If an issue is assigned to a user, that user is claiming responsibility for the issue.
  • Customers working with a Google Technical Account Manager or Customer Engineer can ask them to reach out internally to expedite investigation and resolution of this issue.

Terraform Version & Provider Version(s)

Terraform v1.9.7
on linux_amd64

  • provider registry.terraform.io/hashicorp/google v7.4.0
  • provider registry.terraform.io/hashicorp/google-beta v7.4.0

Affected Resource(s)

google_cloud_quotas_quota_preference

Terraform Configuration

resource "google_cloud_quotas_quota_preference" "project_gpus_quotas_preference" {
  parent = var.parent
  dimensions = {
    region = "europe-west9"
  }
  service       = "aiplatform.googleapis.com"
  quota_id      = "RestrictedImageTrainingV100GPUsPerProjectPerRegion"
  quota_config {
    preferred_value = "0"
  }
}

Debug Output

No response

Expected Behavior

  1. Terraform apply creates the Quota preference
  2. Next terraform plan shows no changes

Actual Behavior

  1. Terraform apply creates the Quota preference
  2. Next terraform plan shows diff:
# google_cloud_quotas_quota_preference.project_gpus_quotas_preference will be updated in-place
  ~ resource "google_cloud_quotas_quota_preference" "project_gpus_quotas_preference" {
[REDACTED]
      ~ quota_config {
          + **preferred_value = "0"**
        }
    }
    }

Steps to reproduce

  1. terraform apply

Important Factoids

We have already considered using lifecycle ignore changes for the 'preferred_value' as workaround.

However, we can not since we need sometime later to increase some specific 'quota_id'.

References

The existing issue 19202 does not match our issue, because we could manage 'preferred_value' correctly when the value is not "0".

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions