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

[Bug]: lexv2models/intent: *.next_step.intent.slot missing values #35345

Open
YakDriver opened this issue Jan 17, 2024 · 1 comment
Open

[Bug]: lexv2models/intent: *.next_step.intent.slot missing values #35345

YakDriver opened this issue Jan 17, 2024 · 1 comment
Labels
bug Addresses a defect in current functionality. service/lexv2models Issues and PRs that pertain to the lexv2models service.

Comments

@YakDriver
Copy link
Member

Terraform Core Version

1.6.6

AWS Provider Version

5.32.1

Affected Resource(s)

  • aws_lexv2models_intent

Expected Behavior

slot needs values, in addition to value.

Actual Behavior

slot does not have values, in addition to value.

When the shape value is "List", it indicates that the values field contains a list of slot values (not currently available in the AWS provider). When the value is "Scalar", it indicates that the value field contains a single value (available in the AWS provider).

values is a list of one or more values that the user provided for the slot. However, the challenge is that values is self-referential causing the potential for infinite recursion. This needs to be examined and a solution figured out.

Relevant Error/Panic Output Snippet

No response

Terraform Configuration Files

resource "aws_lexv2models_intent" "test" {
  bot_id      = aws_lexv2models_bot.test.id
  bot_version = aws_lexv2models_bot_locale.test.bot_version
  name        = "test"
  locale_id   = aws_lexv2models_bot_locale.test.locale_id

  fulfillment_code_hook {
    active  = true
    enabled = true

    fulfillment_updates_specification {
      active             = true
      timeout_in_seconds = 10

      start_response {
        allow_interrupt  = true
        delay_in_seconds = 5

        message_group {
          message {
            plain_text_message {
              value = "hej"
            }
          }
        }
      }

      update_response {
        allow_interrupt      = true
        frequency_in_seconds = 5

        message_group {
          message {
            plain_text_message {
              value = "hej"
            }
          }
        }
      }
    }

    post_fulfillment_status_specification {
      failure_conditional {
        active = true

        conditional_branch {
          name = "test"

          condition {
            expression_string = "slot1 = \"test\""
          }

          next_step {
            session_attributes = {
              slot1 = "roligt"
              slot2 = "roligt2"
            }

            dialog_action {
              type                  = "CloseIntent"
              slot_to_elicit        = "slot1"
              suppress_next_message = true
            }

            intent {
              name = "test"
              slot {
                map_block_key = "test"
                shape         = "List"

                values {
                  map_block_key = "test2"
                  shape         = "List"

                  values {
                    map_block_key = "test3"
                    shape         = "List"
                  }
                }
              }
            }
          }

          response {
            allow_interrupt = true

            message_group {
              message {
                plain_text_message {
                  value = "hej"
                }
              }
            }
          }
        }

        default_branch {
          next_step {
            dialog_action {
              type           = "CloseIntent"
              slot_to_elicit = "slot1"
            }

            session_attributes = {
              slot1 = "hallon"
            }
          }

          response {
            allow_interrupt = true

            message_group {
              message {
                plain_text_message {
                  value = "safriduo"
                }
              }
            }
          }
        }
      }
    }
  }
}

Steps to Reproduce

  1. terraform apply

Debug Output

No response

Panic Output

No response

Important Factoids

No response

References

Would you like to implement a fix?

None

@YakDriver YakDriver added the bug Addresses a defect in current functionality. label Jan 17, 2024
Copy link

Community Note

Voting for Prioritization

  • Please vote on this issue by adding a 👍 reaction to the original post to help the community and maintainers prioritize this request.
  • Please see our prioritization guide for information on how we prioritize.
  • 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.

Volunteering to Work on This Issue

  • If you are interested in working on this issue, please leave a comment.
  • If this would be your first contribution, please review the contribution guide.

@github-actions github-actions bot added the service/lexv2models Issues and PRs that pertain to the lexv2models service. label Jan 17, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Addresses a defect in current functionality. service/lexv2models Issues and PRs that pertain to the lexv2models service.
Projects
None yet
Development

No branches or pull requests

1 participant