{"action":"created","issue":{"url":"https://api.github.com/repos/cloudfoundry/cli/issues/447","labels_url":"https://api.github.com/repos/cloudfoundry/cli/issues/447/labels{/name}","comments_url":"https://api.github.com/repos/cloudfoundry/cli/issues/447/comments","events_url":"https://api.github.com/repos/cloudfoundry/cli/issues/447/events","html_url":"https://github.com/cloudfoundry/cli/issues/447","id":74403113,"number":447,"title":"cli crashed when running `cf app`","user":{"login":"sykesm","id":4517909,"avatar_url":"https://avatars.githubusercontent.com/u/4517909?v=3","gravatar_id":"","url":"https://api.github.com/users/sykesm","html_url":"https://github.com/sykesm","followers_url":"https://api.github.com/users/sykesm/followers","following_url":"https://api.github.com/users/sykesm/following{/other_user}","gists_url":"https://api.github.com/users/sykesm/gists{/gist_id}","starred_url":"https://api.github.com/users/sykesm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sykesm/subscriptions","organizations_url":"https://api.github.com/users/sykesm/orgs","repos_url":"https://api.github.com/users/sykesm/repos","events_url":"https://api.github.com/users/sykesm/events{/privacy}","received_events_url":"https://api.github.com/users/sykesm/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-05-08T15:35:11Z","updated_at":"2015-05-22T18:59:47Z","closed_at":null,"body":"```\r\n$ CF_TRACE=true cf app grace\r\n\r\nVERSION:\r\n6.11.2-2a26d55\r\n\r\n\r\nREQUEST: [2015-05-08T11:33:25-04:00]\r\nGET /v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/apps?q=name%3Agrace&inline-relations-depth=1 HTTP/1.1\r\nHost: api.diego-2.cf-app.com\r\nAccept: application/json\r\nAuthorization: [PRIVATE DATA HIDDEN]\r\nContent-Type: application/json\r\nUser-Agent: go-cli 6.11.2-2a26d55 / darwin\r\n\r\n\r\n\r\nRESPONSE: [2015-05-08T11:33:25-04:00]\r\nHTTP/1.1 200 OK\r\nContent-Length: 4410\r\nConnection: keep-alive\r\nContent-Type: application/json;charset=utf-8\r\nDate: Fri, 08 May 2015 15:33:23 GMT\r\nServer: nginx\r\nX-Cf-Requestid: b70b5ad0-13c0-4fa7-5404-205b76a5f51d\r\nX-Content-Type-Options: nosniff\r\nX-Vcap-Request-Id: dc52c82c-b9fb-46db-74b6-e17424f27bc0::9d3eeb94-d433-425e-99c7-222f82b38778\r\n\r\n{\r\n  \"total_results\": 1,\r\n  \"total_pages\": 1,\r\n  \"prev_url\": null,\r\n  \"next_url\": null,\r\n  \"resources\": [\r\n    {\r\n      \"metadata\": {\r\n        \"guid\": \"991a6ce0-a332-41ce-b783-8f424f3d605d\",\r\n        \"url\": \"/v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d\",\r\n        \"created_at\": \"2015-05-07T22:42:04Z\",\r\n        \"updated_at\": \"2015-05-08T15:30:07Z\"\r\n      },\r\n      \"entity\": {\r\n        \"name\": \"grace\",\r\n        \"production\": false,\r\n        \"space_guid\": \"fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n        \"stack_guid\": \"ec416550-e87e-4c03-90f3-0b841c0c794d\",\r\n        \"buildpack\": null,\r\n        \"detected_buildpack\": \"Go\",\r\n        \"environment_json\": {\r\n\r\n        },\r\n        \"memory\": 10,\r\n        \"instances\": 1,\r\n        \"disk_quota\": 512,\r\n        \"state\": \"STARTED\",\r\n        \"version\": \"95d55b15-d794-45f2-bdd1-0d836b6cefc1\",\r\n        \"command\": null,\r\n        \"console\": false,\r\n        \"debug\": null,\r\n        \"staging_task_id\": \"76f83b313e0b4704949d8004f141d0ed\",\r\n        \"package_state\": \"STAGED\",\r\n        \"health_check_type\": \"port\",\r\n        \"health_check_timeout\": null,\r\n        \"staging_failed_reason\": null,\r\n        \"diego\": true,\r\n        \"docker_image\": null,\r\n        \"package_updated_at\": \"2015-05-07T22:42:16Z\",\r\n        \"detected_start_command\": \"grace\",\r\n        \"enable_ssh\": false,\r\n        \"space_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n        \"space\": {\r\n          \"metadata\": {\r\n            \"guid\": \"fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n            \"url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n            \"created_at\": \"2015-05-07T18:26:31Z\",\r\n            \"updated_at\": null\r\n          },\r\n          \"entity\": {\r\n            \"name\": \"s\",\r\n            \"organization_guid\": \"a0d82e79-8fb6-48ba-ae57-063474ececef\",\r\n            \"space_quota_definition_guid\": null,\r\n            \"allow_ssh\": true,\r\n            \"organization_url\": \"/v2/organizations/a0d82e79-8fb6-48ba-ae57-063474ececef\",\r\n            \"developers_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/developers\",\r\n            \"managers_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/managers\",\r\n            \"auditors_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/auditors\",\r\n            \"apps_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/apps\",\r\n            \"routes_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/routes\",\r\n            \"domains_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/domains\",\r\n            \"service_instances_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/service_instances\",\r\n            \"app_events_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/app_events\",\r\n            \"events_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/events\",\r\n            \"security_groups_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7/security_groups\"\r\n          }\r\n        },\r\n        \"stack_url\": \"/v2/stacks/ec416550-e87e-4c03-90f3-0b841c0c794d\",\r\n        \"stack\": {\r\n          \"metadata\": {\r\n            \"guid\": \"ec416550-e87e-4c03-90f3-0b841c0c794d\",\r\n            \"url\": \"/v2/stacks/ec416550-e87e-4c03-90f3-0b841c0c794d\",\r\n            \"created_at\": \"2015-05-07T18:23:05Z\",\r\n            \"updated_at\": null\r\n          },\r\n          \"entity\": {\r\n            \"name\": \"cflinuxfs2\",\r\n            \"description\": \"Cloud Foundry Linux-based filesystem\"\r\n          }\r\n        },\r\n        \"events_url\": \"/v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/events\",\r\n        \"service_bindings_url\": \"/v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/service_bindings\",\r\n        \"service_bindings\": [\r\n\r\n        ],\r\n        \"routes_url\": \"/v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/routes\",\r\n        \"routes\": [\r\n          {\r\n            \"metadata\": {\r\n              \"guid\": \"767690b7-01ee-4fd4-a3f2-e3abf93a1d11\",\r\n              \"url\": \"/v2/routes/767690b7-01ee-4fd4-a3f2-e3abf93a1d11\",\r\n              \"created_at\": \"2015-05-07T18:26:42Z\",\r\n              \"updated_at\": null\r\n            },\r\n            \"entity\": {\r\n              \"host\": \"grace\",\r\n              \"domain_guid\": \"32b9535b-c6d1-448b-b9d5-a5e43190fc7a\",\r\n              \"space_guid\": \"fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n              \"path\": \"\",\r\n              \"domain_url\": \"/v2/domains/32b9535b-c6d1-448b-b9d5-a5e43190fc7a\",\r\n              \"space_url\": \"/v2/spaces/fe013e1d-bfbf-4620-84d1-a84160043ba7\",\r\n              \"apps_url\": \"/v2/routes/767690b7-01ee-4fd4-a3f2-e3abf93a1d11/apps\"\r\n            }\r\n          }\r\n        ]\r\n      }\r\n    }\r\n  ]\r\n}\r\nShowing health and status for app grace in org o / space s as admin...\r\n\r\nREQUEST: [2015-05-08T11:33:25-04:00]\r\nGET /v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/summary HTTP/1.1\r\nHost: api.diego-2.cf-app.com\r\nAccept: application/json\r\nAuthorization: [PRIVATE DATA HIDDEN]\r\nContent-Type: application/json\r\nUser-Agent: go-cli 6.11.2-2a26d55 / darwin\r\n\r\n\r\n\r\nRESPONSE: [2015-05-08T11:33:26-04:00]\r\nHTTP/1.1 200 OK\r\nContent-Length: 1003\r\nConnection: keep-alive\r\nContent-Type: application/json;charset=utf-8\r\nDate: Fri, 08 May 2015 15:33:24 GMT\r\nServer: nginx\r\nX-Cf-Requestid: cabfff14-c096-49c6-6888-bd2ef44bcd29\r\nX-Content-Type-Options: nosniff\r\nX-Vcap-Request-Id: 694ea034-c130-4052-7ba7-d373161a656a::7a17667d-babc-4cc6-9a9c-65a2679e2f1c\r\n\r\n{\"guid\":\"991a6ce0-a332-41ce-b783-8f424f3d605d\",\"name\":\"grace\",\"routes\":[{\"guid\":\"767690b7-01ee-4fd4-a3f2-e3abf93a1d11\",\"host\":\"grace\",\"domain\":{\"guid\":\"32b9535b-c6d1-448b-b9d5-a5e43190fc7a\",\"name\":\"diego-2.cf-app.com\"}}],\"running_instances\":1,\"services\":[],\"available_domains\":[{\"guid\":\"32b9535b-c6d1-448b-b9d5-a5e43190fc7a\",\"name\":\"diego-2.cf-app.com\"}],\"name\":\"grace\",\"production\":false,\"space_guid\":\"fe013e1d-bfbf-4620-84d1-a84160043ba7\",\"stack_guid\":\"ec416550-e87e-4c03-90f3-0b841c0c794d\",\"buildpack\":null,\"detected_buildpack\":\"Go\",\"environment_json\":{},\"memory\":10,\"instances\":1,\"disk_quota\":512,\"state\":\"STARTED\",\"version\":\"95d55b15-d794-45f2-bdd1-0d836b6cefc1\",\"command\":null,\"console\":false,\"debug\":null,\"staging_task_id\":\"76f83b313e0b4704949d8004f141d0ed\",\"package_state\":\"STAGED\",\"health_check_type\":\"port\",\"health_check_timeout\":null,\"staging_failed_reason\":null,\"diego\":true,\"docker_image\":null,\"package_updated_at\":\"2015-05-07T22:42:16Z\",\"detected_start_command\":\"grace\",\"enable_ssh\":false}\r\n\r\nREQUEST: [2015-05-08T11:33:26-04:00]\r\nGET /v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/instances HTTP/1.1\r\nHost: api.diego-2.cf-app.com\r\nAccept: application/json\r\nAuthorization: [PRIVATE DATA HIDDEN]\r\nContent-Type: application/json\r\nUser-Agent: go-cli 6.11.2-2a26d55 / darwin\r\n\r\n\r\n\r\nRESPONSE: [2015-05-08T11:33:26-04:00]\r\nHTTP/1.1 200 OK\r\nContent-Length: 44\r\nConnection: keep-alive\r\nContent-Type: application/json;charset=utf-8\r\nDate: Fri, 08 May 2015 15:33:24 GMT\r\nServer: nginx\r\nX-Cf-Requestid: 8b5aaae5-9223-4bdc-752c-bf976a407f6b\r\nX-Content-Type-Options: nosniff\r\nX-Vcap-Request-Id: c57aa977-d728-482d-6b52-e2d57291d72d::c10f30e4-c5d0-4f14-b304-4caaf66de192\r\n\r\n{\"0\":{\"state\":\"RUNNING\",\"since\":1431094265}}\r\n\r\nREQUEST: [2015-05-08T11:33:26-04:00]\r\nGET /v2/apps/991a6ce0-a332-41ce-b783-8f424f3d605d/stats HTTP/1.1\r\nHost: api.diego-2.cf-app.com\r\nAccept: application/json\r\nAuthorization: [PRIVATE DATA HIDDEN]\r\nContent-Type: application/json\r\nUser-Agent: go-cli 6.11.2-2a26d55 / darwin\r\n\r\n\r\n\r\nRESPONSE: [2015-05-08T11:33:26-04:00]\r\nHTTP/1.1 200 OK\r\nContent-Length: 114\r\nConnection: keep-alive\r\nContent-Type: application/json;charset=utf-8\r\nDate: Fri, 08 May 2015 15:33:25 GMT\r\nServer: nginx\r\nX-Cf-Requestid: 8971a961-f147-449c-6b46-5f93457d0bc2\r\nX-Content-Type-Options: nosniff\r\nX-Vcap-Request-Id: 8cbbdabd-0f07-4c2d-7854-b191391f18f6::67dbebe9-8d98-449e-8c84-b10e8c910373\r\n\r\n{\"0\":{\"state\":\"RUNNING\",\"stats\":{\"mem_quota\":10485760,\"disk_quota\":536870912,\"usage\":{\"cpu\":0,\"mem\":0,\"disk\":0}}}}\r\n\r\n\r\n\tAww shucks.\r\n\r\n\tSomething completely unexpected happened. This is a bug in cf.\r\n\tPlease file this bug : https://github.com/cloudfoundry/cli/issues\r\n\tTell us that you ran this command:\r\n\r\n\t\tcf app grace\r\n\r\n\tusing this version of the CLI:\r\n\r\n\t\t6.11.2-2a26d55\r\n\r\n\tand that this error occurred:\r\n\r\n\t\truntime error: index out of range\r\n\r\n\tand this stack trace:\r\n\r\n\t\tgoroutine 1 [running]:\r\n\tmain.generateBacktrace(0xc21000a000, 0x3)\r\n\t\t/Users/pivotal/go-agent/pipelines/Mac-OSX-Unit-Tests/src/github.com/cloudfoundry/cli/main/main.go:177 +0xa9\r\n\tmain.handlePanics(0x109a5d8, 0xc210069540)\r\n\t\t/Users/pivotal/go-agent/pipelines/Mac-OSX-Unit-Tests/src/github.com/cloudfoundry/cli/main/main.go:161 +0x123\r\n\truntime.panic(0x564760, 0xe58c57)\r\n\t\t/usr/local/go/src/pkg/runtime/panic.c:248 +0x106\r\n\tgithub.com/cloudfoundry/cli/cf/api.(*logNoaaRepository).GetContainerMetrics(0xc210250f60, 0xc2100cdea0, 0x24, 0xc210171e40, 0x1, ...)\r\n\t\t/Users/pivotal/go-agent/pipelines/Mac-OSX-Unit-Tests/src/github.com/cloudfoundry/cli/tmp/cli_gopath/src/github.com/cloudfoundry/cli/cf/api/logs_noaa.go:68 +0x275\r\n\tgithub.com/cloudfoundry/cli/cf/commands/application.(*ShowApp).ShowApp(0xc210332240, 0xc2100cdea0, 0x24, 0xc21018a438, 0x5, ...)\r\n\t\t/Users/pivotal/go-agent/pipelines/Mac-OSX-Unit-Tests/src/github.com/cloudfoundry/cli/tmp/cli_gopath/src/github.com/cloudfoundry/cli/cf/commands/application/app.go:112 +0x683\r\n\tgithub.com/c\r\n```"},"comment":{"url":"https://api.github.com/repos/cloudfoundry/cli/issues/comments/104744055","html_url":"https://github.com/cloudfoundry/cli/issues/447#issuecomment-104744055","issue_url":"https://api.github.com/repos/cloudfoundry/cli/issues/447","id":104744055,"user":{"login":"ematpl","id":5836757,"avatar_url":"https://avatars.githubusercontent.com/u/5836757?v=3","gravatar_id":"","url":"https://api.github.com/users/ematpl","html_url":"https://github.com/ematpl","followers_url":"https://api.github.com/users/ematpl/followers","following_url":"https://api.github.com/users/ematpl/following{/other_user}","gists_url":"https://api.github.com/users/ematpl/gists{/gist_id}","starred_url":"https://api.github.com/users/ematpl/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ematpl/subscriptions","organizations_url":"https://api.github.com/users/ematpl/orgs","repos_url":"https://api.github.com/users/ematpl/repos","events_url":"https://api.github.com/users/ematpl/events{/privacy}","received_events_url":"https://api.github.com/users/ematpl/received_events","type":"User","site_admin":false},"created_at":"2015-05-22T18:59:47Z","updated_at":"2015-05-22T18:59:47Z","body":"I've also run into this issue recently with 6.11.3. Can provide steps to reproduce with an app running on diego (basically, delete the app's DesiredLRP from Diego and then do `cf app` while it's missing).\r\n\r\nThanks,\r\nEric"}}