Open IchordeDionysos opened 3 weeks ago
Given the API responds with the field being set, this seems to be an issue on the provider side.
I did already check whether there is custom code that would alter the field? But here is nothing that would do that: https://github.com/GoogleCloudPlatform/magic-modules/blob/main/mmv1/products/cloudbuild/Trigger.yaml#L40-L44
The parsing of the field service_account_email
seems pretty standard, so I don't know where the issue may come from 😭
Confirmed permadiff issue when data google_service_account
is used for google_cloudbuild_trigger
Community Note
Terraform Version & Provider Version(s)
Terraform v1.9.3 on darwin_arm64
Affected Resource(s)
google_cloudbuild_trigger
Terraform Configuration
Debug Output
https://gist.github.com/IchordeDionysos/09814666b86c79dd162c64c6a2e51bed
Expected Behavior
The second plan doesn't produce any diffs.
Actual Behavior
Planning the project with the configuration always results in diffs.
In the state file the
service_account_email
is empty:What's interesting is that this warning is shown, which relates to the fact that the
service_account_email
is empty in the state:Steps to reproduce
terraform apply
terraform plan
Important Factoids
This happens if you use
data.google_service_account.default.email
anddata.google_service_account.default.name
.The response of the creation operation of the trigger returns the
service_account_email
as it's passed.Also, after creating the trigger, the GET request returns the
service_account_email
as it's passed.References
No response
b/377499977