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

azurerm_app_configuration_key bad request after moving to 3.36.0 #19711

Closed
1 task done
krukowskid opened this issue Dec 16, 2022 · 4 comments · Fixed by #19722
Closed
1 task done

azurerm_app_configuration_key bad request after moving to 3.36.0 #19711

krukowskid opened this issue Dec 16, 2022 · 4 comments · Fixed by #19722
Labels
Milestone

Comments

@krukowskid
Copy link
Contributor

krukowskid commented Dec 16, 2022

Is there an existing issue for this?

  • I have searched the existing issues

Community Note

  • Please vote on this issue by adding a 👍 reaction to the original issue to help the community and maintainers prioritize this request
  • Please do not leave "+1" or "me too" comments, they generate extra noise for issue followers and do not help prioritize the request
  • If you are interested in working on this issue or have submitted a pull request, please leave a comment

Terraform Version

1.3.5

AzureRM Provider Version

3.36.0

Affected Resource(s)/Data Source(s)

azurerm_app_configuration_key

Terraform Configuration Files

locals {
  app_configuration = flatten([
    for label_key, config in var.app_configuration : [
      for entry_key, entry in config.values : {
        key   = entry_key
        value = entry
        label = config.label
        type  = config.type
      }
    ]
  ])
}

resource "azurerm_app_configuration_key" "this" {
  for_each               = { for entry in local.app_configuration : entry.key => entry }
  configuration_store_id = var.app_configuration_id
  key                    = "${var.app_configuration_key_prefix}:${each.value.key}"
  type                   = each.value.type
  label                  = each.value.label
  value                  = each.value.type == "kv" ? each.value.value : null
  vault_key_reference    = each.value.type == "vault" ? "${var.key_vault_uri}secrets/${each.value.value}" : null
}

Debug Output/Panic Output

https://gist.github.com/krukowskid/a3a88c83657a0ed36cce66c0e4c6c90c

Expected Behaviour

Configuration should be retrieved during refresh in terraform plan/apply like in previous version of module

Actual Behaviour

error: while checking for key's "" existence: appconfiguration.BaseClient#GetKey
Value: Failure responding to request: StatusCode=400 -- Original Error: autorest/azure: error response cannot be parsed: {"" '\x00' '\x00'} error: EOF

Steps to Reproduce

terraform init
terraform plan

Important Factoids

federated credentials auth

References

#19470

@krukowskid krukowskid added the bug label Dec 16, 2022
@github-actions github-actions bot removed the bug label Dec 16, 2022
@arkiaconsulting
Copy link

Git the same error after moving from 3.33.0 to 3.36.0

@ziyeqf
Copy link
Contributor

ziyeqf commented Dec 19, 2022

Hi @krukowskid and @arkiaconsulting , sorry for introduced this bug, a pr (#19722) has been submitted to fix it.

@github-actions
Copy link

github-actions bot commented Jan 3, 2023

This functionality has been released in v3.37.0 of the Terraform Provider. Please see the Terraform documentation on provider versioning or reach out if you need any assistance upgrading.

For further feature requests or bug reports with this functionality, please create a new GitHub issue following the template. Thank you!

@github-actions
Copy link

github-actions bot commented Feb 3, 2023

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.

@github-actions github-actions bot locked as resolved and limited conversation to collaborators Feb 3, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants