-
Notifications
You must be signed in to change notification settings - Fork 9.6k
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
Terraform Module Registry incorrectly shows Inputs as required if default = null #21417
Comments
Thanks for reporting this, @JustinGrote ! Your 0.2.1 link did not work for me but these did: https://registry.terraform.io/modules/JustinGrote/azure-function-powershell/azurerm/0.2.2?tab=inputs At a glance, it looks like the registry does not distinguish |
Same here - https://registry.terraform.io/modules/terraform-aws-modules/vpc/aws/2.21.0?tab=inputs as reported in terraform-aws-vpc issue. Do you have any updates on when this will be fixed, @mildwonkey ? |
Same for the official consul module. Four variables are shown as required on the Terraform Registry page, even though all of them are optional as shown in This is confusing for potential users of a module, so I hope it will get fixed soon! |
Sorry to bother but this is a very frustrating issue for many new users of the modules (I hear this rather often). Is there any way to give this issue a higher priority? |
@jbardin @mildwonkey Any chance this can get fixed before the issue hits its 2-year birthday? |
@mildwonkey @jbardin sorry to do it, but any thoughts / progress / rumblings about this one for ya'll on the terraform team? Every time I see the disclaimer that we include in all module READMEs at Cloud Posse regarding this issue it hurts 😞 |
Hi @Gowiem ! I checked in with our (internal) Registry team, and they are still aware of this issue. Unfortunately it's not something the terraform core team can do anything about, but the Registry team hasn't forgotten about it, and it's on their backlog. |
@mildwonkey figured it was something along those lines. Thanks for following up -- it's much appreciated! |
@mildwonkey bumping this again. one of my colleagues just randomly hit this and reviewing this thread is a real headscratcher for an issue that seems like a fairly low-hanging fruit? |
Hi! I don't work at HashiCorp anymore, so I have no insight into issues.
sorry I couldn't help!
…---------- Forwarded message ---------
From: Jonas Steinberg ***@***.***>
Date: Fri, Feb 18, 2022 at 10:55 AM
Subject: Re: [hashicorp/terraform] Terraform Module Registry incorrectly
shows Inputs as required if default = null (#21417)
To: hashicorp/terraform ***@***.***>
Cc: Kristin Laemmert ***@***.***>, Mention <
***@***.***>
@mildwonkey <https://github.com/mildwonkey> bumping this again. one of my
colleagues just randomly hit this and reviewing this thread is a real
headscratcher for an issue that seems like a fairly low-hanging fruit?
—
Reply to this email directly, view it on GitHub
<#21417 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/ABPMFJTM4EL3QSHMEGPMEPTU3ZTVNANCNFSM4HPKJBKA>
.
Triage notifications on the go with GitHub Mobile for iOS
<https://apps.apple.com/app/apple-store/id1477376905?ct=notification-email&mt=8&pt=524675>
or Android
<https://play.google.com/store/apps/details?id=com.github.android&referrer=utm_campaign%3Dnotification-email%26utm_medium%3Demail%26utm_source%3Dgithub>.
You are receiving this because you were mentioned.Message ID:
***@***.***>
|
wowzers. alright then well best of luck to you haha. well folks looks like we're headed back to "workaround city." |
@jonassteinberg1: Speaking with the Registry team, the issue is slowly rising closer to the top of the list but currently no ETA. |
Also highlighting as problem here too |
Just to share how I've been getting around this issue in the meantime -- I've been setting the optional input variable's default to If it is equal to Hope this helps someone! 🙂 |
TF 1.3 - alpha, introduce optional inputs attributes: https://github.com/hashicorp/terraform/releases/tag/v1.3.0-alpha20220803 |
Hi everyone, variable "example" {
type = string
nullable = false
} Only available in Terraform v1.1.0 + The default value for Setting this doesn't do anything either in regards to this particular open case :( variable "aci_dns_label" {
type = string
description = "DNS label to assign onto the Azure Container Group."
nullable = false
} |
Hi all, This was fixed by the Terraform Registry team a couple months ago. We can actually see the fix in the screenshot in the comment just above this one: A catch with this is that the registry only analyzes the module configuration during the initial import from GitHub and so this adjustment is only effective for module versions that have been published since this change was released. I don't know exactly when that was but I know it was in early August 2022, because I can see the registry team's code change at the beginning of August and the previous comment showing its effect was posted on August 12. The registry does not ever re-visit modules that were previously loaded into it, so historical module versions that were imported with these input variables incorrectly marked as required will, unfortunately, always show the input variables in that way. Module authors will need to publish new versions of their modules for the update to take effect. Because the fix has been merged to the Terraform Registry codebase and deployed, I'm going to close this. Thanks for reporting this and sorry for the delay in closing this issue once it was fixed. |
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. |
See my module for example:
https://registry.terraform.io/modules/JustinGrote/azure-function-powershell/azurerm/
azure_active_directory_id is default=null, so it is an optional variable, but shows as required on the registry.
The text was updated successfully, but these errors were encountered: