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

awscc_lex_bot_alias lifecycle {ignore_changes} does not ignore changes #1962

Open
rug-grygiel opened this issue Aug 18, 2024 · 1 comment
Open

Comments

@rug-grygiel
Copy link

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 other comments that do not add relevant new information or questions, 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
  • The resources and data sources in this provider are generated from the CloudFormation schema, so they can only support the actions that the underlying schema supports. For this reason submitted bugs should be limited to defects in the generation and runtime code of the provider. Customizing behavior of the resource, or noting a gap in behavior are not valid bugs and should be submitted as enhancements to AWS via the CloudFormation Open Coverage Roadmap.

Terraform CLI and Terraform AWS Cloud Control Provider Version

Terraform v1.7.5
on linux_amd64

  • provider registry.terraform.io/hashicorp/archive v2.4.2
  • provider registry.terraform.io/hashicorp/aws v5.57.0
  • provider registry.terraform.io/hashicorp/awscc v1.4.0
  • provider registry.terraform.io/hashicorp/external v2.3.3
  • provider registry.terraform.io/hashicorp/local v2.5.1
  • provider registry.terraform.io/hashicorp/null v3.2.2
  • provider registry.terraform.io/hashicorp/random v3.6.2

Affected Resource(s)

  • awscc_lex_bot_alias

Terraform Configuration Files

resource "awscc_lex_bot_alias" "calculate" {
  bot_alias_name = "calculate"
  bot_id  = aws_cloudformation_stack.calculator.outputs.BotId
  bot_version = aws_lexv2models_bot_version.calculator-bot-version.bot_version
  description    = "Calculate"
  bot_alias_locale_settings = local.calculator-aliases-locale-specification
  
  bot_alias_tags = [{
    key   = "environment"
    value = "poc"
  }]

  conversation_log_settings = {
    audio_log_settings = [{
      enabled = true
      destination = {
        s3_bucket = {
          log_prefix    = "poc"
          s3_bucket_arn = aws_s3_bucket.conversation_logs.arn
        }
      }
    }]
    text_log_settings = [{
      enabled = false
      destination = {
        cloudwatch = {
          log_prefix               = "poc"
          cloudwatch_log_group_arn = aws_cloudwatch_log_group.attribute-log-group.arn
        }
      }
    }]
  lifecycle {
    ignore_changes = [
      conversation_log_settings
    ]
  }
  }

Expected Behavior

Expected lifecycle to ignore changes but it did not.

Actual Behavior

Acted as if ignore_changes was not present.

Steps to Reproduce

  1. terraform apply
  2. terraform plan

Important Factoids

I tried Ignoring conversation_log_settings and sub-levels with no success.

References

@quixoticmonk
Copy link
Collaborator

quixoticmonk commented Sep 11, 2024

As with #1961 , the issue seems to be on sentiment_analysis_settings which is set to a default false value from the API when it is not set on the config. If you set the lifecycle rule below, you wouldn't see the issue with the subsequent applies. I would keep #1961 open as we would like to investigate that further.

    lifecycle {
    ignore_changes = [
      sentiment_analysis_settings
    ]
  }

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants