Skip to content
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

coalesce does not work with data output parameter #23520

Closed
davidshay opened this issue Nov 28, 2019 · 2 comments
Closed

coalesce does not work with data output parameter #23520

davidshay opened this issue Nov 28, 2019 · 2 comments
Labels
bug config v0.12 Issues (primarily bugs) reported against v0.12 releases

Comments

@davidshay
Copy link

davidshay commented Nov 28, 2019

Terraform Version

Terraform v0.12.16
+ provider.aws v2.40.0
+ provider.external v1.2.0

Terraform Configuration Files

data "aws_vpc" "vpc" {
  default= true
}

data "aws_subnet_ids" "subnets" {
  vpc_id = data.aws_vpc.vpc.id
}

output "subnet" {
    value = coalesce(data.aws_subnet_ids.subnets.ids ...)
}

Debug Output

Crash Output

Expected Behavior

Outputs:

subnet = subnet-05f4cf7c847430427

Actual Behavior

Error: Invalid expanding argument value

  on test.tf line 18, in output "subnet":
  18:     value = coalesce(data.aws_subnet_ids.vpc_etl_pubsnet1.ids ...)

The expanding argument (indicated by ...) must be of a tuple, list, or set
type.

Steps to Reproduce

  1. terraform init
  2. terraform apply

Additional Context

It actually works fine from the Terraform console.

References

@danieldreier danieldreier added bug v0.12 Issues (primarily bugs) reported against v0.12 releases labels Dec 2, 2019
@hashibot
Copy link
Contributor

Hello! 🤖

This issue seems to be covering the same problem or request as #22404, so we're going to close it just to consolidate the discussion over there. Thanks!

@ghost
Copy link

ghost commented Apr 1, 2020

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.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked and limited conversation to collaborators Apr 1, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug config v0.12 Issues (primarily bugs) reported against v0.12 releases
Projects
None yet
Development

No branches or pull requests

3 participants