From fed3ea9e044e0d4d4f6a8805a96088b0a431b280 Mon Sep 17 00:00:00 2001 From: Daniel Schmidt Date: Tue, 20 Jan 2026 20:23:31 +0100 Subject: [PATCH] use value without deprecations after validating --- internal/terraform/eval_for_each.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/internal/terraform/eval_for_each.go b/internal/terraform/eval_for_each.go index d605f127ec..1a011a4564 100644 --- a/internal/terraform/eval_for_each.go +++ b/internal/terraform/eval_for_each.go @@ -329,7 +329,7 @@ func (ev *forEachEvaluator) validateResourceOrActionForEach(forEachVal cty.Value } // We don't care about the returned value here, only the diagnostics - _, deprecationDiags := ev.ctx.Deprecations().Validate(forEachVal, ev.ctx.Path().Module(), ev.expr.Range().Ptr()) + forEachVal, deprecationDiags := ev.ctx.Deprecations().Validate(forEachVal, ev.ctx.Path().Module(), ev.expr.Range().Ptr()) diags = diags.Append(deprecationDiags)