Skip to content

Version 7.22 has broken oci_resourcemanager_stacks (and probably others) - "Invalid address to set: []string{"stacks", "0", "terraform_version"}"Β #2460

@cweeks72

Description

@cweeks72

Community Note

  • Please vote on this issue by adding a πŸ‘ reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version and Provider Version

opentofu v1.9.1 and resourcemanager itself
provider version v7.22.0

Affected Resource(s)

data.oci_resourcemanager_stacks and probably others touched in 93716ca

Terraform Configuration Files

provider "oci" {
}

data "oci_resourcemanager_stacks" "stack" {
    compartment_id = "anycompartmentcontainingresourcemanagerstacks"
}

output "test" {
    value = data.oci_resourcemanager_stacks.stack
}

Debug Output

Panic Output

data.oci_resourcemanager_stacks.stack: Reading...

Planning failed. OpenTofu encountered an error while generating this plan.

β•·
β”‚ Error: Invalid address to set: []string{"stacks", "0", "terraform_version"}
β”‚ 
β”‚   with data.oci_resourcemanager_stacks.stack,
β”‚   on test.tf line 11, in data "oci_resourcemanager_stacks" "stack":
β”‚   11: data "oci_resourcemanager_stacks" "stack" {
β”‚ 

Expected Behavior

I should have received a stack output from terraform. I did not, I got an error instead, see above.

Actual Behavior

I got an error.

Steps to Reproduce

  1. Just plan the above with appropriate inputs. It's super simple to recreate the problem.

Important Factoids

Forcing the version to v7.21.0 fixes the issue.

References

The issue was introduced in the commit 93716ca for certain - rolling back to the previous version fixes the issue, and you can see it's trying to add the "terraform_version" attribute, my guess is, incorrectly.

Metadata

Metadata

Assignees

No one assigned

    Labels

    In-ProgressTerraform Team is working on the reproduce & fixbug

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions