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

Terraform 0.14.8 zipmap panic: value is marked, so must be unmarked first #28049

Closed
syphernl opened this issue Mar 11, 2021 · 2 comments · Fixed by #28116
Closed

Terraform 0.14.8 zipmap panic: value is marked, so must be unmarked first #28049

syphernl opened this issue Mar 11, 2021 · 2 comments · Fixed by #28116
Assignees
Labels
bug config confirmed a Terraform Core team member has reproduced this issue dependencies Auto-pinning

Comments

@syphernl
Copy link

syphernl commented Mar 11, 2021

Terraform Version

❯ terraform version
Terraform v0.14.8
+ provider registry.terraform.io/hashicorp/local v2.1.0
+ provider registry.terraform.io/hashicorp/random v3.1.0
...

Terraform Configuration Files

test_module/main.tf

resource "random_string" "password" {
  length  = 32
  special = false
}

output "test_password" {
  value       = random_string.password.result
  description = "Test password"
  sensitive   = true
}

main.tf

module "test" {
  source = "./test_module"
}

module "demo_container" {
  source          = "git::https://github.com/cloudposse/terraform-aws-ecs-container-definition.git?ref=master"
  container_name  = "demo-container"
  container_image = "nginxdemos/hello:latest"

  secrets = [
    {
      name      = "PASSWORD",
      valueFrom = module.test.test_password
    }
  ]

  environment = [
    {
      name  = "APP_ENV",
      value = "production",
    }
  ]

  port_mappings = [
    {
      containerPort = 80
      hostPort      = 80
      protocol      = "tcp"
    }
  ]

  healthcheck = {
    command     = ["CMD-SHELL", "curl -f http://localhost:80/health || exit 1"]
    retries     = 5
    timeout     = 5
    interval    = 30
    startPeriod = 30
  }
}

output "demo_container" {
  value = module.demo_container.json_map_encoded
}

...

Debug Output

https://gist.github.com/syphernl/5cb73895e2c357d2c66b89694a60b0ff

Crash Output

The console did not actually indicate it crashed, but it gave the following output:
https://gist.github.com/syphernl/960ac4009adc501b943e0699fd487fa4

Expected Behavior

terraform plan should not crash.

Actual Behavior

terraform plan terminates with Call to function "zipmap" failed: panic in function implementation: value is marked, so must be unmarked first

Steps to Reproduce

Using the two files mentioned above run:

  • terraform init
  • terraform plan

During plan Terraform will crash.

Additional Context

References

Similar to #27954

@syphernl syphernl added bug new new issue not yet triaged labels Mar 11, 2021
@syphernl syphernl changed the title Terraform 0.14.8 panic: value is marked, so must be unmarked first Terraform 0.14.8 zipmap panic: value is marked, so must be unmarked first Mar 11, 2021
@jbardin jbardin added confirmed a Terraform Core team member has reproduced this issue and removed new new issue not yet triaged labels Mar 11, 2021
@jbardin jbardin self-assigned this Mar 11, 2021
@danieltharp
Copy link

Noting this behavior is still persisting in v0.14.10.

@ghost
Copy link

ghost commented Apr 16, 2021

I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues.

If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.

@ghost ghost locked as resolved and limited conversation to collaborators Apr 16, 2021
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
bug config confirmed a Terraform Core team member has reproduced this issue dependencies Auto-pinning
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants