Skip to content

bugfix: provider validation for subscription_id#27178

Merged
manicminer merged 4 commits intomainfrom
bugfix/provider-validation-for-subscription-id
Aug 23, 2024
Merged

bugfix: provider validation for subscription_id#27178
manicminer merged 4 commits intomainfrom
bugfix/provider-validation-for-subscription-id

Conversation

@manicminer
Copy link
Contributor

@manicminer manicminer commented Aug 23, 2024

Using the following test configuration:

terraform {
  required_providers {
    azurerm = {
      source  = "hashicorp/azurerm"
      version = "4.0.0"
    }
  }
}

provider "azurerm" {
  features {}
}

data "azurerm_client_config" "test" {}

resource "azurerm_resource_group" "test" {
  name     = "aaatest-foo"
  location = "westeurope"
}

terraform validate with no subscription ID

Screenshot 2024-08-23 at 19 27 16

terraform validate with invalid subscription ID

Screenshot 2024-08-23 at 19 28 04

terraform validate with valid subscription ID

SCR-20240823-r25

terraform plan with no subscription ID

Screenshot 2024-08-23 at 19 29 45

terraform plan with invalid subscription ID

Screenshot 2024-08-23 at 19 30 16

terraform plan with valid subscription ID

SCR-20240823-r59

Change Log

Below please provide what should go into the changelog (if anything) conforming to the Changelog Format documented here.

  • provider: fix a validation bug that prevents terraform validate from working when subscription_id is not specified

This is a (please select all that apply):

  • Bug Fix
  • New Feature (ie adding a service, resource, or data source)
  • Enhancement
  • Breaking Change

Note

If this PR changes meaningfully during the course of review please update the title and description as required.

fixes: #27154 #27175

Copy link
Member

@mbfrahry mbfrahry left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

Copy link
Collaborator

@katbyte katbyte left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 🧪

@manicminer manicminer merged commit 6ba240b into main Aug 23, 2024
@manicminer manicminer deleted the bugfix/provider-validation-for-subscription-id branch August 23, 2024 19:17
manicminer added a commit that referenced this pull request Aug 23, 2024
@github-actions
Copy link
Contributor

I'm going to lock this pull request because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active contributions.
If you have found a problem that seems related to this change, 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 Sep 23, 2024
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

The argument "subscription_id" is required, but no definition was found

3 participants