{"action":"opened","issue":{"url":"https://api.github.com/repos/hashicorp/terraform/issues/8234","repository_url":"https://api.github.com/repos/hashicorp/terraform","labels_url":"https://api.github.com/repos/hashicorp/terraform/issues/8234/labels{/name}","comments_url":"https://api.github.com/repos/hashicorp/terraform/issues/8234/comments","events_url":"https://api.github.com/repos/hashicorp/terraform/issues/8234/events","html_url":"https://github.com/hashicorp/terraform/issues/8234","id":171494970,"number":8234,"title":"Lookup plan does not fail with missing variable","user":{"login":"jeffastorey","id":1882220,"avatar_url":"https://avatars.githubusercontent.com/u/1882220?v=3","gravatar_id":"","url":"https://api.github.com/users/jeffastorey","html_url":"https://github.com/jeffastorey","followers_url":"https://api.github.com/users/jeffastorey/followers","following_url":"https://api.github.com/users/jeffastorey/following{/other_user}","gists_url":"https://api.github.com/users/jeffastorey/gists{/gist_id}","starred_url":"https://api.github.com/users/jeffastorey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jeffastorey/subscriptions","organizations_url":"https://api.github.com/users/jeffastorey/orgs","repos_url":"https://api.github.com/users/jeffastorey/repos","events_url":"https://api.github.com/users/jeffastorey/events{/privacy}","received_events_url":"https://api.github.com/users/jeffastorey/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":0,"created_at":"2016-08-16T19:15:41Z","updated_at":"2016-08-16T19:15:41Z","closed_at":null,"body":"Running a `terraform plan` on an AWS security group rule that references an undefined variable still successfully creates a plan. In the example below, the variable named `somevariable` is missing the `var` - it should be `var.somevariable`. When the `var` is omitted, the plan still succeeds, but the apply fails. I don't think the plan should successfully be created when there is a syntax error.\r\n\r\n```\r\nresource \"aws_security_group_rule\" \"dummy_rule\" {\r\n  security_group_id = \"sg-xxxxxx\"\r\n\r\n  type = \"egress\"\r\n\r\n  cidr_blocks = [\"${split(\",\", lookup(somevariable, \"string\"))}\"]\r\n  protocol    = \"tcp\"\r\n  from_port   = 1234\r\n  to_port     = 1234\r\n}\r\n```\r\nTerraform version is 0.6.16"}}
{"actor":{"display_login":"jeffastorey"}}