GoogleCloudPlatform / cloud-foundation-toolkit

The Cloud Foundation toolkit provides GCP best practices as code.
Apache License 2.0
965 stars 457 forks source link

ERROR: Provider produced inconsistent result after tf-apply: google_project_iam_member.dataflow_logging_sink_writer #1263

Closed macksclark closed 2 years ago

macksclark commented 2 years ago

Not sure if this is the correct repo to file this bug in but I am seeing a provider error in tf-apply with the gcr.io/cloud-foundation-cicd repo on version gcr.io/cloud-foundation-cicd/cft/developer-tools-light@sha256:d881ce4ff2a73fa0877dd357af798a431a601b2ccfe5a140837bcb883cd3f011 which we've been using since 2021-06 (but the error is new). We observed the error many times last week, but have not seen it over the past few days so either it has been fixed or it is a flake.

The error is:

Step #2 - "Apply": Error: Provider produced inconsistent result after apply
Step #2 - "Apply": 
Step #2 - "Apply": When applying changes to
Step #2 - "Apply": google_project_iam_member.dataflow_logging_sink_writer, provider
Step #2 - "Apply": "registry.terraform.io/hashicorp/google" produced an unexpected new value:
Step #2 - "Apply": Root resource was present, but now absent.
Step #2 - "Apply": 
Step #2 - "Apply": This is a bug in the provider, which should be reported in the provider's own
Step #2 - "Apply": issue tracker.
Step #2 - "Apply": 
Finished Step #2 - "Apply"
ERROR
ERROR: build step 2 "gcr.io/cloud-foundation-cicd/cft/developer-tools-light@sha256:d881ce4ff2a73fa0877dd357af798a431a601b2ccfe5a140837bcb883cd3f011" failed: step exited with non-zero status: 1
--------------------------------------------------------------------------------

Would anyone be able to help us resolve this?

bharathkkb commented 2 years ago

Hi @macksclark I think this is unrelated to the container but rather related to the provider. I would recommend opening an issue in https://github.com/hashicorp/terraform-provider-google. Something worth looking is if there has been any provider changes in your TF configuration. Feel free to reopen if still an issue.