Throw an error in time_rotating
resource when an attribute is updated with an unknown value in the configuration
#227
Labels
enhancement
New feature or request
Terraform CLI and Provider Versions
Time v3.2.1
Use Cases or Problem Statement
Relates #146, #149, #218
The
time_rotating
resource currently throws anError: Provider produced inconsistent final plan
error whenever an attribute is updated with an unknown value. This is due to the resource calculating attribute values during planning, so when the previously unknown values become known during the update, the final calculated values are inconsistent with the previously planned values.Proposal
Normally, resolving this issue involves skipping the calculation of values during planning and only setting the attributes during apply. However, this approach will trigger a resource change before the scheduled rotation even if the final calculated attribute values result in no change in configuration.
Therefore, the resource should throw an error when this situation occurs indicating to practitioners that only known values may be used when updating the resource's configuration.
This should be implemented in the resource's
ModifyPlan()
method by checking for unknown values in the configuration after checking that the state is not null (indicating an update).How much impact is this issue causing?
Low
Additional Information
No response
Code of Conduct
The text was updated successfully, but these errors were encountered: