{"action":"closed","number":921,"pull_request":{"url":"https://api.github.com/repos/chef/inspec/pulls/921","id":81449085,"html_url":"https://github.com/chef/inspec/pull/921","diff_url":"https://github.com/chef/inspec/pull/921.diff","patch_url":"https://github.com/chef/inspec/pull/921.patch","issue_url":"https://api.github.com/repos/chef/inspec/issues/921","number":921,"state":"closed","locked":false,"title":"Fix errant 0 exit status on SSH errors","user":{"login":"stevendanna","id":852371,"avatar_url":"https://avatars.githubusercontent.com/u/852371?v=3","gravatar_id":"","url":"https://api.github.com/users/stevendanna","html_url":"https://github.com/stevendanna","followers_url":"https://api.github.com/users/stevendanna/followers","following_url":"https://api.github.com/users/stevendanna/following{/other_user}","gists_url":"https://api.github.com/users/stevendanna/gists{/gist_id}","starred_url":"https://api.github.com/users/stevendanna/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/stevendanna/subscriptions","organizations_url":"https://api.github.com/users/stevendanna/orgs","repos_url":"https://api.github.com/users/stevendanna/repos","events_url":"https://api.github.com/users/stevendanna/events{/privacy}","received_events_url":"https://api.github.com/users/stevendanna/received_events","type":"User","site_admin":false},"body":"Thor, the command line framework we use, rescues Errno::EPIPE\r\nexceptions and exits 0.  It does this because for many unix-style\r\ncommand line applications it is a good decision.  For example, if your\r\ncommand is being used in a pipeline with head(1):\r\n\r\n    my_command | head -10\r\n\r\nIt will get an EPIPE after head exits. You don't want this command to\r\nfail because of the EPIPE as it is what you expected.\r\n\r\nHowever, in our case, the SSH transport will raise EPIPE if the remote\r\nserver unexpectedly closed the connection.  This can happen, for\r\nexample, if your ssh configuration has a bad ProxyCommand configuration.\r\nIn these cases we do not want to exit successfully.\r\n\r\nExplicitly rescuing the EPIPE in Inspec::Backend#create solves the issue\r\nreported by users, but it may be better to rescue this exception in\r\nTrain itself.\r\n\r\nFixes #840\r\n\r\nSigned-off-by: Steven Danna <steve@chef.io>","created_at":"2016-08-16T10:33:37Z","updated_at":"2016-08-17T09:32:43Z","closed_at":"2016-08-17T09:32:43Z","merged_at":null,"merge_commit_sha":"33062a75c07cb7b1a8e70d94948b7a45735d4af3","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/chef/inspec/pulls/921/commits","review_comments_url":"https://api.github.com/repos/chef/inspec/pulls/921/comments","review_comment_url":"https://api.github.com/repos/chef/inspec/pulls/comments{/number}","comments_url":"https://api.github.com/repos/chef/inspec/issues/921/comments","statuses_url":"https://api.github.com/repos/chef/inspec/statuses/a4875f06614e4fc5cf4d0687cc939df7cf5c205c","head":{"label":"chef:ssd/issue-840","ref":"ssd/issue-840","sha":"a4875f06614e4fc5cf4d0687cc939df7cf5c205c","user":{"login":"chef","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?v=3","gravatar_id":"","url":"https://api.github.com/users/chef","html_url":"https://github.com/chef","followers_url":"https://api.github.com/users/chef/followers","following_url":"https://api.github.com/users/chef/following{/other_user}","gists_url":"https://api.github.com/users/chef/gists{/gist_id}","starred_url":"https://api.github.com/users/chef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chef/subscriptions","organizations_url":"https://api.github.com/users/chef/orgs","repos_url":"https://api.github.com/users/chef/repos","events_url":"https://api.github.com/users/chef/events{/privacy}","received_events_url":"https://api.github.com/users/chef/received_events","type":"Organization","site_admin":false},"repo":{"id":41571541,"name":"inspec","full_name":"chef/inspec","owner":{"login":"chef","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?v=3","gravatar_id":"","url":"https://api.github.com/users/chef","html_url":"https://github.com/chef","followers_url":"https://api.github.com/users/chef/followers","following_url":"https://api.github.com/users/chef/following{/other_user}","gists_url":"https://api.github.com/users/chef/gists{/gist_id}","starred_url":"https://api.github.com/users/chef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chef/subscriptions","organizations_url":"https://api.github.com/users/chef/orgs","repos_url":"https://api.github.com/users/chef/repos","events_url":"https://api.github.com/users/chef/events{/privacy}","received_events_url":"https://api.github.com/users/chef/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/chef/inspec","description":"InSpec: Auditing and Testing Framework","fork":false,"url":"https://api.github.com/repos/chef/inspec","forks_url":"https://api.github.com/repos/chef/inspec/forks","keys_url":"https://api.github.com/repos/chef/inspec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chef/inspec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chef/inspec/teams","hooks_url":"https://api.github.com/repos/chef/inspec/hooks","issue_events_url":"https://api.github.com/repos/chef/inspec/issues/events{/number}","events_url":"https://api.github.com/repos/chef/inspec/events","assignees_url":"https://api.github.com/repos/chef/inspec/assignees{/user}","branches_url":"https://api.github.com/repos/chef/inspec/branches{/branch}","tags_url":"https://api.github.com/repos/chef/inspec/tags","blobs_url":"https://api.github.com/repos/chef/inspec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chef/inspec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chef/inspec/git/refs{/sha}","trees_url":"https://api.github.com/repos/chef/inspec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chef/inspec/statuses/{sha}","languages_url":"https://api.github.com/repos/chef/inspec/languages","stargazers_url":"https://api.github.com/repos/chef/inspec/stargazers","contributors_url":"https://api.github.com/repos/chef/inspec/contributors","subscribers_url":"https://api.github.com/repos/chef/inspec/subscribers","subscription_url":"https://api.github.com/repos/chef/inspec/subscription","commits_url":"https://api.github.com/repos/chef/inspec/commits{/sha}","git_commits_url":"https://api.github.com/repos/chef/inspec/git/commits{/sha}","comments_url":"https://api.github.com/repos/chef/inspec/comments{/number}","issue_comment_url":"https://api.github.com/repos/chef/inspec/issues/comments{/number}","contents_url":"https://api.github.com/repos/chef/inspec/contents/{+path}","compare_url":"https://api.github.com/repos/chef/inspec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chef/inspec/merges","archive_url":"https://api.github.com/repos/chef/inspec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chef/inspec/downloads","issues_url":"https://api.github.com/repos/chef/inspec/issues{/number}","pulls_url":"https://api.github.com/repos/chef/inspec/pulls{/number}","milestones_url":"https://api.github.com/repos/chef/inspec/milestones{/number}","notifications_url":"https://api.github.com/repos/chef/inspec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chef/inspec/labels{/name}","releases_url":"https://api.github.com/repos/chef/inspec/releases{/id}","deployments_url":"https://api.github.com/repos/chef/inspec/deployments","created_at":"2015-08-28T22:16:01Z","updated_at":"2016-08-17T03:07:51Z","pushed_at":"2016-08-17T07:37:30Z","git_url":"git://github.com/chef/inspec.git","ssh_url":"git@github.com:chef/inspec.git","clone_url":"https://github.com/chef/inspec.git","svn_url":"https://github.com/chef/inspec","homepage":"","size":3030,"stargazers_count":408,"watchers_count":408,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":69,"mirror_url":null,"open_issues_count":182,"forks":69,"open_issues":182,"watchers":408,"default_branch":"master"}},"base":{"label":"chef:master","ref":"master","sha":"c43f3fe155727281a839ab4858b35f6ef4353768","user":{"login":"chef","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?v=3","gravatar_id":"","url":"https://api.github.com/users/chef","html_url":"https://github.com/chef","followers_url":"https://api.github.com/users/chef/followers","following_url":"https://api.github.com/users/chef/following{/other_user}","gists_url":"https://api.github.com/users/chef/gists{/gist_id}","starred_url":"https://api.github.com/users/chef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chef/subscriptions","organizations_url":"https://api.github.com/users/chef/orgs","repos_url":"https://api.github.com/users/chef/repos","events_url":"https://api.github.com/users/chef/events{/privacy}","received_events_url":"https://api.github.com/users/chef/received_events","type":"Organization","site_admin":false},"repo":{"id":41571541,"name":"inspec","full_name":"chef/inspec","owner":{"login":"chef","id":29740,"avatar_url":"https://avatars.githubusercontent.com/u/29740?v=3","gravatar_id":"","url":"https://api.github.com/users/chef","html_url":"https://github.com/chef","followers_url":"https://api.github.com/users/chef/followers","following_url":"https://api.github.com/users/chef/following{/other_user}","gists_url":"https://api.github.com/users/chef/gists{/gist_id}","starred_url":"https://api.github.com/users/chef/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/chef/subscriptions","organizations_url":"https://api.github.com/users/chef/orgs","repos_url":"https://api.github.com/users/chef/repos","events_url":"https://api.github.com/users/chef/events{/privacy}","received_events_url":"https://api.github.com/users/chef/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/chef/inspec","description":"InSpec: Auditing and Testing Framework","fork":false,"url":"https://api.github.com/repos/chef/inspec","forks_url":"https://api.github.com/repos/chef/inspec/forks","keys_url":"https://api.github.com/repos/chef/inspec/keys{/key_id}","collaborators_url":"https://api.github.com/repos/chef/inspec/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/chef/inspec/teams","hooks_url":"https://api.github.com/repos/chef/inspec/hooks","issue_events_url":"https://api.github.com/repos/chef/inspec/issues/events{/number}","events_url":"https://api.github.com/repos/chef/inspec/events","assignees_url":"https://api.github.com/repos/chef/inspec/assignees{/user}","branches_url":"https://api.github.com/repos/chef/inspec/branches{/branch}","tags_url":"https://api.github.com/repos/chef/inspec/tags","blobs_url":"https://api.github.com/repos/chef/inspec/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/chef/inspec/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/chef/inspec/git/refs{/sha}","trees_url":"https://api.github.com/repos/chef/inspec/git/trees{/sha}","statuses_url":"https://api.github.com/repos/chef/inspec/statuses/{sha}","languages_url":"https://api.github.com/repos/chef/inspec/languages","stargazers_url":"https://api.github.com/repos/chef/inspec/stargazers","contributors_url":"https://api.github.com/repos/chef/inspec/contributors","subscribers_url":"https://api.github.com/repos/chef/inspec/subscribers","subscription_url":"https://api.github.com/repos/chef/inspec/subscription","commits_url":"https://api.github.com/repos/chef/inspec/commits{/sha}","git_commits_url":"https://api.github.com/repos/chef/inspec/git/commits{/sha}","comments_url":"https://api.github.com/repos/chef/inspec/comments{/number}","issue_comment_url":"https://api.github.com/repos/chef/inspec/issues/comments{/number}","contents_url":"https://api.github.com/repos/chef/inspec/contents/{+path}","compare_url":"https://api.github.com/repos/chef/inspec/compare/{base}...{head}","merges_url":"https://api.github.com/repos/chef/inspec/merges","archive_url":"https://api.github.com/repos/chef/inspec/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/chef/inspec/downloads","issues_url":"https://api.github.com/repos/chef/inspec/issues{/number}","pulls_url":"https://api.github.com/repos/chef/inspec/pulls{/number}","milestones_url":"https://api.github.com/repos/chef/inspec/milestones{/number}","notifications_url":"https://api.github.com/repos/chef/inspec/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/chef/inspec/labels{/name}","releases_url":"https://api.github.com/repos/chef/inspec/releases{/id}","deployments_url":"https://api.github.com/repos/chef/inspec/deployments","created_at":"2015-08-28T22:16:01Z","updated_at":"2016-08-17T03:07:51Z","pushed_at":"2016-08-17T07:37:30Z","git_url":"git://github.com/chef/inspec.git","ssh_url":"git@github.com:chef/inspec.git","clone_url":"https://github.com/chef/inspec.git","svn_url":"https://github.com/chef/inspec","homepage":"","size":3030,"stargazers_count":408,"watchers_count":408,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":69,"mirror_url":null,"open_issues_count":182,"forks":69,"open_issues":182,"watchers":408,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/chef/inspec/pulls/921"},"html":{"href":"https://github.com/chef/inspec/pull/921"},"issue":{"href":"https://api.github.com/repos/chef/inspec/issues/921"},"comments":{"href":"https://api.github.com/repos/chef/inspec/issues/921/comments"},"review_comments":{"href":"https://api.github.com/repos/chef/inspec/pulls/921/comments"},"review_comment":{"href":"https://api.github.com/repos/chef/inspec/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/chef/inspec/pulls/921/commits"},"statuses":{"href":"https://api.github.com/repos/chef/inspec/statuses/a4875f06614e4fc5cf4d0687cc939df7cf5c205c"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":4,"review_comments":0,"commits":1,"additions":4,"deletions":0,"changed_files":1}}
{"actor":{"display_login":"chris-rock"}}