{"action":"created","issue":{"url":"https://api.github.com/repos/hashicorp/terraform/issues/13219","repository_url":"https://api.github.com/repos/hashicorp/terraform","labels_url":"https://api.github.com/repos/hashicorp/terraform/issues/13219/labels{/name}","comments_url":"https://api.github.com/repos/hashicorp/terraform/issues/13219/comments","events_url":"https://api.github.com/repos/hashicorp/terraform/issues/13219/events","html_url":"https://github.com/hashicorp/terraform/issues/13219","id":218296976,"number":13219,"title":"Google provider API error with Zone","user":{"login":"luhkevin","id":342515,"avatar_url":"https://avatars0.githubusercontent.com/u/342515?v=3","gravatar_id":"","url":"https://api.github.com/users/luhkevin","html_url":"https://github.com/luhkevin","followers_url":"https://api.github.com/users/luhkevin/followers","following_url":"https://api.github.com/users/luhkevin/following{/other_user}","gists_url":"https://api.github.com/users/luhkevin/gists{/gist_id}","starred_url":"https://api.github.com/users/luhkevin/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/luhkevin/subscriptions","organizations_url":"https://api.github.com/users/luhkevin/orgs","repos_url":"https://api.github.com/users/luhkevin/repos","events_url":"https://api.github.com/users/luhkevin/events{/privacy}","received_events_url":"https://api.github.com/users/luhkevin/received_events","type":"User","site_admin":false},"labels":[{"id":85946957,"url":"https://api.github.com/repos/hashicorp/terraform/labels/bug","name":"bug","color":"f7c6c7","default":true},{"id":135750563,"url":"https://api.github.com/repos/hashicorp/terraform/labels/provider/google-cloud","name":"provider/google-cloud","color":"bfdadc","default":false}],"state":"open","locked":false,"assignee":{"login":"paddyforan","id":59249,"avatar_url":"https://avatars3.githubusercontent.com/u/59249?v=3","gravatar_id":"","url":"https://api.github.com/users/paddyforan","html_url":"https://github.com/paddyforan","followers_url":"https://api.github.com/users/paddyforan/followers","following_url":"https://api.github.com/users/paddyforan/following{/other_user}","gists_url":"https://api.github.com/users/paddyforan/gists{/gist_id}","starred_url":"https://api.github.com/users/paddyforan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paddyforan/subscriptions","organizations_url":"https://api.github.com/users/paddyforan/orgs","repos_url":"https://api.github.com/users/paddyforan/repos","events_url":"https://api.github.com/users/paddyforan/events{/privacy}","received_events_url":"https://api.github.com/users/paddyforan/received_events","type":"User","site_admin":false},"assignees":[{"login":"paddyforan","id":59249,"avatar_url":"https://avatars3.githubusercontent.com/u/59249?v=3","gravatar_id":"","url":"https://api.github.com/users/paddyforan","html_url":"https://github.com/paddyforan","followers_url":"https://api.github.com/users/paddyforan/followers","following_url":"https://api.github.com/users/paddyforan/following{/other_user}","gists_url":"https://api.github.com/users/paddyforan/gists{/gist_id}","starred_url":"https://api.github.com/users/paddyforan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paddyforan/subscriptions","organizations_url":"https://api.github.com/users/paddyforan/orgs","repos_url":"https://api.github.com/users/paddyforan/repos","events_url":"https://api.github.com/users/paddyforan/events{/privacy}","received_events_url":"https://api.github.com/users/paddyforan/received_events","type":"User","site_admin":false}],"milestone":null,"comments":1,"created_at":"2017-03-30T19:04:56Z","updated_at":"2017-04-13T21:55:56Z","closed_at":null,"body":"### Terraform Version\r\nTerraform v0.8.6\r\n\r\n### Affected Resource(s)\r\nPlease list the resources as a list, for example:\r\n- google_compute_instance\r\n\r\nIf this issue appears to affect multiple resources, it may be an issue with Terraform's core, so please mention this.\r\n\r\n### Terraform Configuration Files\r\n```hcl\r\nprovider \"google\" {\r\n  credentials = \"${file(\"${var.credentials_file_path}\")}\"\r\n  project = \"${var.project_name}\"\r\n  region = \"${var.region}\"\r\n}\r\n\r\nresource \"google_compute_instance\" \"launch-test\" {\r\n  count = 1\r\n  name = \"${var.instance_name}\"\r\n  machine_type = \"${var.machine_type}\"\r\n  zone = \"${var.region}\"\r\n\r\n  disk {\r\n    image = \"${var.disk_image}\" // the operating system (and Linux flavour) that your machine will run\r\n    size = 80\r\n  }\r\n \r\n  metadata {\r\n    ssh-keys = \"${var.ssh_username}:${file(\"${var.public_key_path}\")}\"\r\n  }\r\n\r\n  create_timeout = 15\r\n\r\n  network_interface {\r\n    network = \"default\"\r\n    access_config {\r\n      // Ephemeral IP - leaving this block empty will generate a new external IP and assign it to the machine\r\n    }\r\n  }\r\n\r\n  // docker auth\r\n  provisioner \"remote-exec\" {\r\n    connection {\r\n      type        = \"ssh\"\r\n      user        = \"${var.ssh_username}\"\r\n      private_key = \"${file(\"${var.private_key_path}\")}\"\r\n      agent       = false\r\n    }\r\n\r\n    inline = [\r\n      \"mkdir -p /home/${var.ssh_username}/.docker\"\r\n    ]\r\n  }\r\n\r\n  provisioner \"file\" {\r\n    source = \"${var.docker_credentials_file_path}\"\r\n    destination = \"/home/${var.ssh_username}/.docker/config.json\"\r\n\r\n    connection {\r\n      type        = \"ssh\"\r\n      user        = \"${var.ssh_username}\"\r\n      private_key = \"${file(\"${var.private_key_path}\")}\"\r\n      agent       = false\r\n    }\r\n  }\r\n\r\n  provisioner \"file\" {\r\n    source = \"${var.parent_exec_script_dir}/${var.local_exec_script_dir}\"\r\n    destination = \"/tmp\"\r\n\r\n    connection {\r\n      type        = \"ssh\"\r\n      user        = \"${var.ssh_username}\"\r\n      private_key = \"${file(\"${var.private_key_path}\")}\"\r\n      agent       = false\r\n    }\r\n  }\r\n\r\n  provisioner \"remote-exec\" {\r\n    connection {\r\n      type        = \"ssh\"\r\n      user        = \"${var.ssh_username}\"\r\n      private_key = \"${file(\"${var.private_key_path}\")}\"\r\n      agent       = false\r\n    }\r\n\r\n    inline = [\r\n      \"chmod +x /tmp/${var.local_exec_script_dir}/${var.exec_script}\",\r\n      \"/tmp/${var.local_exec_script_dir}/${var.exec_script} ${var.exec_args}\"\r\n    ]\r\n  }\r\n}\r\n```\r\n\r\n### Debug Output\r\nI will post the actual debug output if I'm able to reproduce it. For now, here is the terraform output: https://gist.github.com/luhkevin/0972e83ff427a91ede5a7da5562fa432\r\n\r\nI managed to reproduce it, here's the gist (It's quite long):\r\nhttps://gist.github.com/luhkevin/34a2619d05f0d36761a68bd1030082b8\r\n\r\n### Expected Behavior\r\nTerraform should have gotten the list of zones correctly\r\n\r\n### Actual Behavior\r\nThis works correctly most of the time (75%-ish, so far). But the other times, Terraform errors out and prints:\r\n```\r\ngoogle_compute_instance.launch-test: Error loading zone 'us-west1-b': Get https://www.googleapis.com/compute/v1/projects/my-project-id/zones/us-west1-b?alt=json: stream error: stream ID 1; PROTOCOL_ERROR\r\n```\r\n\r\n### Steps to Reproduce\r\nPlease list the steps required to reproduce the issue, for example:\r\nI just ran the standard command: `terraform apply -state=terraform.tfstate -state-out=terraform.tfstate ./terraform`\r\n"},"comment":{"url":"https://api.github.com/repos/hashicorp/terraform/issues/comments/294032059","html_url":"https://github.com/hashicorp/terraform/issues/13219#issuecomment-294032059","issue_url":"https://api.github.com/repos/hashicorp/terraform/issues/13219","id":294032059,"user":{"login":"paddyforan","id":59249,"avatar_url":"https://avatars3.githubusercontent.com/u/59249?v=3","gravatar_id":"","url":"https://api.github.com/users/paddyforan","html_url":"https://github.com/paddyforan","followers_url":"https://api.github.com/users/paddyforan/followers","following_url":"https://api.github.com/users/paddyforan/following{/other_user}","gists_url":"https://api.github.com/users/paddyforan/gists{/gist_id}","starred_url":"https://api.github.com/users/paddyforan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paddyforan/subscriptions","organizations_url":"https://api.github.com/users/paddyforan/orgs","repos_url":"https://api.github.com/users/paddyforan/repos","events_url":"https://api.github.com/users/paddyforan/events{/privacy}","received_events_url":"https://api.github.com/users/paddyforan/received_events","type":"User","site_admin":false},"created_at":"2017-04-13T21:55:56Z","updated_at":"2017-04-13T21:55:56Z","body":"Hi @luhkevin! Sorry for the trouble, and thanks for opening an issue. Gonna try to get to the bottom of this, so sorry for the late response.\r\n\r\nWhat is your `region` variable set to?"}}
{"actor":{"display_login":"paddyforan"}}