Could you please create a new release/version with the output fixe ?
bkamin29 opened this issue · 1 comments
bkamin29 commented
When using this sub_module with terraform-google-slo
, i have an error concerning the output scheduler_job
:
Error: Inconsistent conditional result types
on .terraform/modules/slo_generator.slo-hp-fr-availability.slo_cloud_function/outputs.tf line 23, in output "scheduler_job":
23: value = var.scheduler_job == null ? google_cloud_scheduler_job.job : var.scheduler_job
|----------------
| google_cloud_scheduler_job.job is empty tuple
| var.scheduler_job is object with 1 attribute "name"
The true and false result expressions must have consistent types. The given
expressions are tuple and object, respectively.
I think the value is not good, google_cloud_scheduler_job.job have many element, it's list. In our case the output have to be :
output "scheduler_job" { value = var.scheduler_job == null ? google_cloud_scheduler_job.job[0] : var.scheduler_job description = "The Cloud Scheduler job instance" }
I have test and it's work fine now
morgante commented
This is now fixed in the v1.4.1 release. Thanks for the report/reminder!