Open matalo33 opened 1 year ago
CompareResourceNames is used
To workaround I added a lifecycle argument:
lifecycle {
ignore_changes = [project]
}
As @edwardmedia mentioned CompareResourceNames is used which is actually taking care of always trimming the id. I couldn't reproduce the issue because I have no service created before this change.
I couldn't find any changelog too as you mentioned. Can you please try to reproduce once again?
Community Note
modular-magician
user, it is either in the process of being autogenerated, or is planned to be autogenerated soon. If an issue is assigned to a user, that user is claiming responsibility for the issue. If an issue is assigned tohashibot
, a community member has claimed the issue already.Terraform Version
terraform 1.6.1 provider 5.0.0
Affected Resource(s)
Terraform Configuration Files
Expected Behavior
no-op
Actual Behavior
Steps to Reproduce
Upgrading the provider to v5 causes terraform to want to recreate all enabled project services. I confirmed running plan & apply does actually disable the APIs before enabling them again.
It seems this might be because the
id
attribute of thegoogle_project
has changed from<project id>
toprojects/<project id>
This does not appear to be mentioned in the change log, or the v5 upgrade guide.
Have we done something wrong here, or is this behaviour that others are experiencing? Lastly, what is the best way to work around this issue? Running this apply is obviously very disruptive.
b/306360723