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

Empty ID #108

Closed
cristim opened this issue Nov 25, 2020 · 1 comment · Fixed by #114
Closed

Empty ID #108

cristim opened this issue Nov 25, 2020 · 1 comment · Fixed by #114
Labels
bug 🐛 An issue with the system

Comments

@cristim
Copy link

cristim commented Nov 25, 2020

Found a bug? Maybe our Slack Community can help. - I asked about 24h ago but didn't receive any answers yet.
Slack Community

Describe the Bug

  • After upgrading to the latest version(this used to work in 0.18.0) I'm always getting an empty label ID, regardless what I tried. I might be wrong in the way I use the module after the changes introduced in 0.19, but I tried to follow the docs to the best of my abilities/understanding.
  • The same happens when using module.label.id instead of module.label.id_full.
  • I also played with the enabled and id_length_limit parameters, but to no avail yet. Am I missing anything?

Here's a simplified code example that can be used to show this behavior.

module "label" {
  source          = "git::https://github.com/cloudposse/terraform-null-label.git?ref=0.21.0"
  context         = module.this.context
  enabled         = true
  id_length_limit = 10
}
output "ID" {
  value = "'${module.label.id_full}'"
}

Apply complete! Resources: 0 added, 0 changed, 0 destroyed.
Outputs:
ID = ''

Expected Behavior

I get a non-empty random'ish value in the ID output.

Steps to Reproduce

  1. Use the above code example, pasted into a main.tf file, stored in a new directory next to the context.tf file currently expected by terraform-null-label.
  2. Run 'terraform init && terraform apply'
  3. See the empty ID in the list of outputs.

Screenshots

See above code snippets

Environment (please complete the following information):

Anything that will help us triage the bug will help. Here are some ideas:

  • macOS Catalina 10.15.7

Additional Context

N/A

@cristim cristim added the bug 🐛 An issue with the system label Nov 25, 2020
@cristim
Copy link
Author

cristim commented Dec 2, 2020

I eventually figured it out, I just needed to set a few of the apparently required variables mentioned in context.tf, I just wish those would be more clearly documented as required

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug 🐛 An issue with the system
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant