Skip to content
This repository has been archived by the owner on Mar 27, 2024. It is now read-only.

Provider produced inconsistent result after apply #141

Open
CodeOpsMS opened this issue Sep 21, 2023 · 2 comments
Open

Provider produced inconsistent result after apply #141

CodeOpsMS opened this issue Sep 21, 2023 · 2 comments
Assignees
Labels
bug Something isn't working

Comments

@CodeOpsMS
Copy link

CodeOpsMS commented Sep 21, 2023

Terraform Version

Terraform v1.5.5
on darwin_amd64

  • provider registry.terraform.io/rewe-digital/sonarcloud v0.5.2

Affected Resource(s)

registry.terraform.io/rewe-digital/sonarcloud v0.5.2

Terraform Configuration Files

module "base_sonarcloud_user_group_permissions" {
source = ".//modules/sonarcloud_user_group_permissions"
for_each = {
for name, project in local.base_sonarcloud_user_groups : project.name => project
if contains(["Collaboration"], project.name) # Nur Projekte mit "Collaboration" als Benutzergruppe
}

name = each.value.name
permissions = local.env.permission
}

TF plan

Terraform used the selected providers to generate the following execution plan. Resource actions are indicated with the following symbols:
~ update in-place

Terraform will perform the following actions:

module.base_sonarcloud_user_group_permissions["Collaboration"].sonarcloud_user_group_permissions.user_group_permissions will be updated in-place
~ resource "sonarcloud_user_group_permissions" "user_group_permissions" {
~ description = "Collaboration product team" -> (known after apply)
~ id = "756591" -> (known after apply)
name = "Collaboration"
~ permissions = [
+ "profileadmin",
+ "provisioning",
+ "scan",
# (2 unchanged elements hidden)
]
}

Plan: 0 to add, 1 to change, 0 to destroy.

Changes to Outputs:

  • sonarcloud_user_group_permissions = [
    • {
      • Collaboration = {
        • user_group_permissions = {
          • description = (known after apply)
          • id = (known after apply)
          • name = "Collaboration"
          • permissions = [
            • "admin",
            • "gateadmin",
            • "profileadmin",
            • "provisioning",
            • "scan",
              ]
          • project_key = null
            }
            }
            },
            ]

Do you want to perform these actions?
Terraform will perform the actions described above.
Only 'yes' will be accepted to approve.

Enter a value:

TF Apply

module.base_sonarcloud_user_group_permissions["Collaboration"].sonarcloud_user_group_permissions.user_group_permissions: Modifying... [id=756591]

│ Error: Provider produced inconsistent result after apply

│ When applying changes to
│ module.base_sonarcloud_user_group_permissions["Collaboration"].sonarcloud_user_group_permissions.user_group_permissions, provider
│ "provider["registry.terraform.io/rewe-digital/sonarcloud"]" produced an unexpected new value: .project_key: was null, but now
│ cty.StringVal("").

│ This is a bug in the provider, which should be reported in the provider's own issue tracker.

@CodeOpsMS CodeOpsMS added the bug Something isn't working label Sep 21, 2023
@quinyx-max
Copy link

quinyx-max commented Nov 6, 2023

i have the same problem

Error: Provider produced inconsistent result after apply

When applying changes to
sonarcloud_user_group_permissions.group-permissions["Quality-Managers"],
provider "provider[\"registry.terraform.io/rewe-digital/sonarcloud\"]"
produced an unexpected new value: .project_key: was null, but now
cty.StringVal("").

This is a bug in the provider, which should be reported in the provider's own
issue tracker.

@MickSheppardWB
Copy link

I have the same issue as well

│ Error: Provider produced inconsistent result after apply
│ 
│ When applying changes to
│ sonarcloud_user_group_permissions.team_quality_permissions["gitlab_squad_qa_quality"],
│ provider "provider[\"registry.terraform.io/rewe-digital/sonarcloud\"]"
│ produced an unexpected new value: .project_key: was null, but now
│ cty.StringVal("").
│ 
│ This is a bug in the provider, which should be reported in the provider's
│ own issue tracker.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

4 participants