Loading...
Loading...
### Terraform Version ```shell Terraform v1.3.5 on f00 + provider registry.terraform.io/hashicorp/aws v5.26.0 + provider registry.terraform.io/hashicorp/null v3.2.2 ``` ### Terraform Configuration Files ```terraform data "aws_lambda_invocation" "xyz" { for_each = { for k, v in local.functions : k => v if lookup(v, "xyz", null) != null } function_name = module.foo.bar[each.key].baz input = jsonencode(each.value["xyz"]["foobar"]) // make it happen only during apply (trying to fix the change not recorded in plan) depends_on = [null_resource.apply_anchor] lifecycle { postcondition { condition = jsondecode(self.result) == each.value["xyz"]["barfoo"] error_message = "wanted barfoo but got something else" } } } ``` ### Debug Output ``` ╷ │ Error: Missing pending object in plan │ │ on abc/abc.tf line 420: │ 420: data "aws_lambda_invocation" "xyz" { │ │ Instance │ module.abc.data.aws_lambda_invocation.xyz["123"] is │ marked as having a change pending but that change is not recorded in the │ plan. This is a bug in Terraform; please report it. ╵ Releasing state lock. This may take a few moments... ``` ### Expected Behavior It should either work all the time or fail all the time. Ideally work all the time and not fail randomly sometimes. ### Actual Behavior It fails sometimes. ### Steps to Reproduce ``` terraform init terraform plan -out tf.plan terraform apply tf.plan ``` ### Additional Context _No response_ ### References _No response_
Click on a version to see all relevant bugs
Terraform Integration
Learn more about where this data comes from
Bug Scrub Advisor
Streamline upgrades with automated vendor bug scrubs
BugZero Enterprise
Wish you caught this bug sooner? Get proactive today.