Closed t0yv0 closed 2 months ago
Thanks for the report and the repro here!
@iwahbe I've done some investigation on this around https://github.com/pulumi/pulumi-terraform-bridge/issues/2032 which is likely a duplicated/very related.
I'll take over if that's ok
This issue has been addressed in PR #2061 and shipped in release v3.88.0.
What happened?
There is machinery in MakeTerraformInputs specifically makeTerraformUnknown that tries to substitute reasonably shaped empty values for unknowns when the schema indicates lists or sets. Unfortunately this is involved in Check turnaround, so that Pulumi providers start swallowing these unknowns even at Check level, and definitely continue swallowing them during diffs.
Primarily this leads to surprising and unreliable Diff behavior where unknowns are replaced by empties.
But occasionally it also leads to substantial problems; in case of pulumi/pulumi-aws#3835 this uncovered a latent bug making the provider panic on this empty input that would not have otherwise occur in a normal program.
See also:
Example
Customer repro:
Auths receives a secret.Arn which is unknown. However Check translates it to a known value.
Output of
pulumi about
N/A
Additional context
No response
Contributing
Vote on this issue by adding a 👍 reaction. To contribute a fix for this issue, leave a comment (and link to your pull request, if you've opened one already).