[Bug]: Perpetual diff on data_set_identifiers_declarations in aws_quicksight_dashboard and aws_quicksight_analysis #36733
Labels
bug
Addresses a defect in current functionality.
service/quicksight
Issues and PRs that pertain to the quicksight service.
Terraform Core Version
1.7.5
AWS Provider Version
5.43.0,5.38.0
Affected Resource(s)
Expected Behavior
In the
definition
block I have specified multipledata_set_identifiers_declarations
blocks. This applies correctly and that should be the end of the story.Actual Behavior
Terraform shows a perpetual diff in the ordering of the
data_set_identifiers_declarations
blocks. It seems that AWS re-orders them according to some internal whim and Terraform sees this as a diff, and tries to re-apply them in the order they're specified in my definition.I can re-order them in the definition to match this, and there's no diff for this instance of my dashboard - but I am doing this in a module, and when I do it in a different instance of the module, with different dataset names, the order is different.
Relevant Error/Panic Output Snippet
Terraform Configuration Files
Steps to Reproduce
terraform apply
to create the resource.terraform plan
without changing the definition - see that AWS has re-ordered thedata_set_identifiers_declarations
and the plan changes them back to the order in which they're written.Debug Output
No response
Panic Output
No response
Important Factoids
The sort ordering is always consistent within a given dashboard/analysis, even if I delete and recreate. I think the order is based on a hash of the dataset name or something. Obviously the solution is to explicitly sort the values before comparing the definition and the resource state to see if there is a difference.
As in my exampe configuration above, it is possible to use
lifecycle
->ignore_changes
to work around the problem.References
No response
Would you like to implement a fix?
No
The text was updated successfully, but these errors were encountered: