Skip to content

User names not tracked #4546

@mmyers5

Description

@mmyers5

Terraform CLI Version

1.14.3

Terraform Provider Version

2.14.0

Company Name

GameChanger

Terraform Configuration

resource "snowflake_service_user" "ops" {
  name                           = "MY NAME"
  ...
}

Category

category:resource

Object type(s)

resource:user

Expected Behavior

The login_name and display_name resource attributes are defaulted to the name if they are not explicitly declared in the resource. If I change the name, e.g. to "MY NEW NAME", the login_name and display_name should also be set to "MY NEW NAME". Otherwise, the statefile has hidden configuration.

Actual Behavior

The login_name and display_name were set to the old default ("MY NAME") after I changed the name attribute. This led me down a long rabbit hole of trying to figure out why authentication was failing despite the Terraform resource implying that the user name I was using was correct.

Steps to Reproduce

  1. Create a Terraform service user with "MY NAME" and apply changes
  2. Update the resource name property to "MY NEW NAME" and apply changes
  3. Observe the login_name and display_name

How much impact is this issue causing?

Low

Logs

No response

Additional Information

No response

Would you like to implement a fix?

  • Yeah, I'll take it 😎

Metadata

Metadata

Assignees

No one assigned

    Labels

    category:resourceIssue connected to one of the existing/new resources.general-usageImproper usage of the provider or terraform ecosystem or question about the usage.resource:userIssue connected to the snowflake_user resource

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions