-
Notifications
You must be signed in to change notification settings - Fork 9.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Confusing error message: "Inconsistent conditional result types. The given expressions are object and object, respectively." #30562
Comments
Thanks for opening this issue. The two expressions in this conditional are both object types, but two objects with attribute types which are collections or structural types (e.g. For example, the following two objects are convertible: but the following two are not: However, the error message "The given expressions are object and object, respectively" is clearly not helpful here. This ticket will be left open until we have improved this error message. Thanks again for bringing this to our attention! |
Thank you! |
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. |
Terraform Version
Debug Output
https://gist.github.com/orgads/3b408edbceccfe3e259daaa880ffe6d0
Expected Behavior
I expect it to work, as both types are objects.
In my case, I needed it as an input to
merge
.Actual Behavior
The true and false result expressions must have consistent types. The given expressions are object and object, respectively.
Steps to Reproduce
terraform init
terraform apply
References
The text was updated successfully, but these errors were encountered: