Loading...
Loading...
### Terraform Version ```shell 1.10.0-dev (248b10e483f8ab27bac3db2fd1979b7f7a39281a) ``` ### Terraform Configuration Files ```terraform terraform { required_providers { random = { source = "hashicorp/random" } } } ephemeral "random_password" "example" { length = 12 } check "test" { assert { condition = ephemeral.random_password.example.result == "foo" error_message = "password is not foo but ${ephemeral.random_password.example.result}" } } ``` ### Debug Output https://gist.github.com/radeksimko/25af355588d0379fa96fcaab7c2517d8 ### Expected Behavior Warnings not to be duplicated between plan & apply. ### Actual Behavior Duplicate warning diagnostic after `terraform apply` ```sh $ terraform apply ``` ``` ephemeral.random_password.example: Opening... ephemeral.random_password.example: Opening complete after 0s ephemeral.random_password.example: Closing... ephemeral.random_password.example: Closing complete after 0s No changes. Your infrastructure matches the configuration. Terraform has compared your real infrastructure against your configuration and found no differences, so no changes are needed. ephemeral.random_password.example: Opening... ephemeral.random_password.example: Opening complete after 0s ephemeral.random_password.example: Closing... ephemeral.random_password.example: Closing complete after 0s ╷ │ Warning: Check block assertion failed │ │ on main.tf line 15, in check "test": │ 15: condition = ephemeral.random_password.example.result == "foo" │ │ This check failed, but has an invalid error message as described in the other accompanying messages. ╵ ╷ │ Warning: Error message refers to ephemeral values │ │ on main.tf line 16, in check "test": │ 16: error_message = "password is not foo but ${ephemeral.random_password.example.result}" │ │ The error expression used to explain this condition refers to ephemeral values, so Terraform will not display the resulting message. │ │ You can correct this by removing references to ephemeral values, or by using the ephemeralasnull() function on the references to not reveal ephemeral data. │ │ (and one more similar warning elsewhere) ╵ ``` note the last line > (and one more similar warning elsewhere) When I try to disable warning consolidation, I can see the exact same warning. Also this does not occur on `terraform plan`. ### Steps to Reproduce 1. `terraform init` 2. `terraform apply` ### 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.