{"action":"created","comment":{"url":"https://api.github.com/repos/vmware/vic/pulls/comments/70695521","id":70695521,"diff_hunk":"@@ -98,13 +98,21 @@ func (v *Volume) VolumeRm(name string) error {\n \t//FIXME: check whether this is a name or a UUID. UUID expected for now.\n \t_, err := client.Storage.RemoveVolume(storage.NewRemoveVolumeParams().WithName(name))\n \tif err != nil {\n-\t\tif _, ok := err.(*storage.RemoveVolumeNotFound); ok {\n+\n+\t\tswitch err := err.(type) {\n+\n+\t\tcase *storage.RemoveVolumeNotFound:\n \t\t\treturn derr.NewRequestNotFoundError(fmt.Errorf(\"Get %s: no such volume\", name))\n+\n+\t\tcase *storage.RemoveVolumeConflict:\n+\t\t\treturn derr.NewRequestConflictError(fmt.Errorf(\"Volume '%s' is in use\", name))\n+\n+\t\tcase *storage.RemoveVolumeInternalServerError:","path":"lib/apiservers/engine/backends/volume.go","position":14,"original_position":14,"commit_id":"842b1efda52d8bc56b12d2a968f56ff9b7eed839","original_commit_id":"7dd9c2e01fde3fbf9da80ab5c617054c3c80e52f","user":{"login":"matthewavery","id":8620942,"avatar_url":"https://avatars.githubusercontent.com/u/8620942?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewavery","html_url":"https://github.com/matthewavery","followers_url":"https://api.github.com/users/matthewavery/followers","following_url":"https://api.github.com/users/matthewavery/following{/other_user}","gists_url":"https://api.github.com/users/matthewavery/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewavery/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewavery/subscriptions","organizations_url":"https://api.github.com/users/matthewavery/orgs","repos_url":"https://api.github.com/users/matthewavery/repos","events_url":"https://api.github.com/users/matthewavery/events{/privacy}","received_events_url":"https://api.github.com/users/matthewavery/received_events","type":"User","site_admin":false},"body":"yes that would be the case.","created_at":"2016-07-13T19:49:46Z","updated_at":"2016-07-13T19:49:46Z","html_url":"https://github.com/vmware/vic/pull/1485#discussion_r70695521","pull_request_url":"https://api.github.com/repos/vmware/vic/pulls/1485","_links":{"self":{"href":"https://api.github.com/repos/vmware/vic/pulls/comments/70695521"},"html":{"href":"https://github.com/vmware/vic/pull/1485#discussion_r70695521"},"pull_request":{"href":"https://api.github.com/repos/vmware/vic/pulls/1485"}}},"pull_request":{"url":"https://api.github.com/repos/vmware/vic/pulls/1485","id":77344590,"html_url":"https://github.com/vmware/vic/pull/1485","diff_url":"https://github.com/vmware/vic/pull/1485.diff","patch_url":"https://github.com/vmware/vic/pull/1485.patch","issue_url":"https://api.github.com/repos/vmware/vic/issues/1485","number":1485,"state":"open","locked":false,"title":"Unsqash error messages and better error handling","user":{"login":"matthewavery","id":8620942,"avatar_url":"https://avatars.githubusercontent.com/u/8620942?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewavery","html_url":"https://github.com/matthewavery","followers_url":"https://api.github.com/users/matthewavery/followers","following_url":"https://api.github.com/users/matthewavery/following{/other_user}","gists_url":"https://api.github.com/users/matthewavery/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewavery/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewavery/subscriptions","organizations_url":"https://api.github.com/users/matthewavery/orgs","repos_url":"https://api.github.com/users/matthewavery/repos","events_url":"https://api.github.com/users/matthewavery/events{/privacy}","received_events_url":"https://api.github.com/users/matthewavery/received_events","type":"User","site_admin":false},"body":"This removes the useless nature of the dreaded \"error from portlayer server\"","created_at":"2016-07-13T19:11:22Z","updated_at":"2016-07-13T19:49:46Z","closed_at":null,"merged_at":null,"merge_commit_sha":"14154ebf4f621af9fc1c86e08cd8b2465eabe0e9","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/vmware/vic/pulls/1485/commits","review_comments_url":"https://api.github.com/repos/vmware/vic/pulls/1485/comments","review_comment_url":"https://api.github.com/repos/vmware/vic/pulls/comments{/number}","comments_url":"https://api.github.com/repos/vmware/vic/issues/1485/comments","statuses_url":"https://api.github.com/repos/vmware/vic/statuses/842b1efda52d8bc56b12d2a968f56ff9b7eed839","head":{"label":"matthewavery:better-errors","ref":"better-errors","sha":"842b1efda52d8bc56b12d2a968f56ff9b7eed839","user":{"login":"matthewavery","id":8620942,"avatar_url":"https://avatars.githubusercontent.com/u/8620942?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewavery","html_url":"https://github.com/matthewavery","followers_url":"https://api.github.com/users/matthewavery/followers","following_url":"https://api.github.com/users/matthewavery/following{/other_user}","gists_url":"https://api.github.com/users/matthewavery/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewavery/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewavery/subscriptions","organizations_url":"https://api.github.com/users/matthewavery/orgs","repos_url":"https://api.github.com/users/matthewavery/repos","events_url":"https://api.github.com/users/matthewavery/events{/privacy}","received_events_url":"https://api.github.com/users/matthewavery/received_events","type":"User","site_admin":false},"repo":{"id":55441893,"name":"vic","full_name":"matthewavery/vic","owner":{"login":"matthewavery","id":8620942,"avatar_url":"https://avatars.githubusercontent.com/u/8620942?v=3","gravatar_id":"","url":"https://api.github.com/users/matthewavery","html_url":"https://github.com/matthewavery","followers_url":"https://api.github.com/users/matthewavery/followers","following_url":"https://api.github.com/users/matthewavery/following{/other_user}","gists_url":"https://api.github.com/users/matthewavery/gists{/gist_id}","starred_url":"https://api.github.com/users/matthewavery/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/matthewavery/subscriptions","organizations_url":"https://api.github.com/users/matthewavery/orgs","repos_url":"https://api.github.com/users/matthewavery/repos","events_url":"https://api.github.com/users/matthewavery/events{/privacy}","received_events_url":"https://api.github.com/users/matthewavery/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/matthewavery/vic","description":"Integrated containers on vSphere","fork":true,"url":"https://api.github.com/repos/matthewavery/vic","forks_url":"https://api.github.com/repos/matthewavery/vic/forks","keys_url":"https://api.github.com/repos/matthewavery/vic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/matthewavery/vic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/matthewavery/vic/teams","hooks_url":"https://api.github.com/repos/matthewavery/vic/hooks","issue_events_url":"https://api.github.com/repos/matthewavery/vic/issues/events{/number}","events_url":"https://api.github.com/repos/matthewavery/vic/events","assignees_url":"https://api.github.com/repos/matthewavery/vic/assignees{/user}","branches_url":"https://api.github.com/repos/matthewavery/vic/branches{/branch}","tags_url":"https://api.github.com/repos/matthewavery/vic/tags","blobs_url":"https://api.github.com/repos/matthewavery/vic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/matthewavery/vic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/matthewavery/vic/git/refs{/sha}","trees_url":"https://api.github.com/repos/matthewavery/vic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/matthewavery/vic/statuses/{sha}","languages_url":"https://api.github.com/repos/matthewavery/vic/languages","stargazers_url":"https://api.github.com/repos/matthewavery/vic/stargazers","contributors_url":"https://api.github.com/repos/matthewavery/vic/contributors","subscribers_url":"https://api.github.com/repos/matthewavery/vic/subscribers","subscription_url":"https://api.github.com/repos/matthewavery/vic/subscription","commits_url":"https://api.github.com/repos/matthewavery/vic/commits{/sha}","git_commits_url":"https://api.github.com/repos/matthewavery/vic/git/commits{/sha}","comments_url":"https://api.github.com/repos/matthewavery/vic/comments{/number}","issue_comment_url":"https://api.github.com/repos/matthewavery/vic/issues/comments{/number}","contents_url":"https://api.github.com/repos/matthewavery/vic/contents/{+path}","compare_url":"https://api.github.com/repos/matthewavery/vic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/matthewavery/vic/merges","archive_url":"https://api.github.com/repos/matthewavery/vic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/matthewavery/vic/downloads","issues_url":"https://api.github.com/repos/matthewavery/vic/issues{/number}","pulls_url":"https://api.github.com/repos/matthewavery/vic/pulls{/number}","milestones_url":"https://api.github.com/repos/matthewavery/vic/milestones{/number}","notifications_url":"https://api.github.com/repos/matthewavery/vic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/matthewavery/vic/labels{/name}","releases_url":"https://api.github.com/repos/matthewavery/vic/releases{/id}","deployments_url":"https://api.github.com/repos/matthewavery/vic/deployments","created_at":"2016-04-04T20:19:26Z","updated_at":"2016-04-04T20:19:27Z","pushed_at":"2016-07-13T19:41:12Z","git_url":"git://github.com/matthewavery/vic.git","ssh_url":"git@github.com:matthewavery/vic.git","clone_url":"https://github.com/matthewavery/vic.git","svn_url":"https://github.com/matthewavery/vic","homepage":null,"size":26065,"stargazers_count":0,"watchers_count":0,"language":"Go","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"vmware:master","ref":"master","sha":"72a735ad26ccc5d70543afbae7bf82215140bcf7","user":{"login":"vmware","id":473334,"avatar_url":"https://avatars.githubusercontent.com/u/473334?v=3","gravatar_id":"","url":"https://api.github.com/users/vmware","html_url":"https://github.com/vmware","followers_url":"https://api.github.com/users/vmware/followers","following_url":"https://api.github.com/users/vmware/following{/other_user}","gists_url":"https://api.github.com/users/vmware/gists{/gist_id}","starred_url":"https://api.github.com/users/vmware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmware/subscriptions","organizations_url":"https://api.github.com/users/vmware/orgs","repos_url":"https://api.github.com/users/vmware/repos","events_url":"https://api.github.com/users/vmware/events{/privacy}","received_events_url":"https://api.github.com/users/vmware/received_events","type":"Organization","site_admin":false},"repo":{"id":49597898,"name":"vic","full_name":"vmware/vic","owner":{"login":"vmware","id":473334,"avatar_url":"https://avatars.githubusercontent.com/u/473334?v=3","gravatar_id":"","url":"https://api.github.com/users/vmware","html_url":"https://github.com/vmware","followers_url":"https://api.github.com/users/vmware/followers","following_url":"https://api.github.com/users/vmware/following{/other_user}","gists_url":"https://api.github.com/users/vmware/gists{/gist_id}","starred_url":"https://api.github.com/users/vmware/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vmware/subscriptions","organizations_url":"https://api.github.com/users/vmware/orgs","repos_url":"https://api.github.com/users/vmware/repos","events_url":"https://api.github.com/users/vmware/events{/privacy}","received_events_url":"https://api.github.com/users/vmware/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/vmware/vic","description":"Integrated containers on vSphere","fork":false,"url":"https://api.github.com/repos/vmware/vic","forks_url":"https://api.github.com/repos/vmware/vic/forks","keys_url":"https://api.github.com/repos/vmware/vic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vmware/vic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vmware/vic/teams","hooks_url":"https://api.github.com/repos/vmware/vic/hooks","issue_events_url":"https://api.github.com/repos/vmware/vic/issues/events{/number}","events_url":"https://api.github.com/repos/vmware/vic/events","assignees_url":"https://api.github.com/repos/vmware/vic/assignees{/user}","branches_url":"https://api.github.com/repos/vmware/vic/branches{/branch}","tags_url":"https://api.github.com/repos/vmware/vic/tags","blobs_url":"https://api.github.com/repos/vmware/vic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vmware/vic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vmware/vic/git/refs{/sha}","trees_url":"https://api.github.com/repos/vmware/vic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vmware/vic/statuses/{sha}","languages_url":"https://api.github.com/repos/vmware/vic/languages","stargazers_url":"https://api.github.com/repos/vmware/vic/stargazers","contributors_url":"https://api.github.com/repos/vmware/vic/contributors","subscribers_url":"https://api.github.com/repos/vmware/vic/subscribers","subscription_url":"https://api.github.com/repos/vmware/vic/subscription","commits_url":"https://api.github.com/repos/vmware/vic/commits{/sha}","git_commits_url":"https://api.github.com/repos/vmware/vic/git/commits{/sha}","comments_url":"https://api.github.com/repos/vmware/vic/comments{/number}","issue_comment_url":"https://api.github.com/repos/vmware/vic/issues/comments{/number}","contents_url":"https://api.github.com/repos/vmware/vic/contents/{+path}","compare_url":"https://api.github.com/repos/vmware/vic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vmware/vic/merges","archive_url":"https://api.github.com/repos/vmware/vic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vmware/vic/downloads","issues_url":"https://api.github.com/repos/vmware/vic/issues{/number}","pulls_url":"https://api.github.com/repos/vmware/vic/pulls{/number}","milestones_url":"https://api.github.com/repos/vmware/vic/milestones{/number}","notifications_url":"https://api.github.com/repos/vmware/vic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vmware/vic/labels{/name}","releases_url":"https://api.github.com/repos/vmware/vic/releases{/id}","deployments_url":"https://api.github.com/repos/vmware/vic/deployments","created_at":"2016-01-13T19:53:57Z","updated_at":"2016-07-12T18:27:26Z","pushed_at":"2016-07-13T19:48:28Z","git_url":"git://github.com/vmware/vic.git","ssh_url":"git@github.com:vmware/vic.git","clone_url":"https://github.com/vmware/vic.git","svn_url":"https://github.com/vmware/vic","homepage":null,"size":73491,"stargazers_count":100,"watchers_count":100,"language":"Go","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":37,"mirror_url":null,"open_issues_count":438,"forks":37,"open_issues":438,"watchers":100,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/vmware/vic/pulls/1485"},"html":{"href":"https://github.com/vmware/vic/pull/1485"},"issue":{"href":"https://api.github.com/repos/vmware/vic/issues/1485"},"comments":{"href":"https://api.github.com/repos/vmware/vic/issues/1485/comments"},"review_comments":{"href":"https://api.github.com/repos/vmware/vic/pulls/1485/comments"},"review_comment":{"href":"https://api.github.com/repos/vmware/vic/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/vmware/vic/pulls/1485/commits"},"statuses":{"href":"https://api.github.com/repos/vmware/vic/statuses/842b1efda52d8bc56b12d2a968f56ff9b7eed839"}}}}
{"actor":{"display_login":"matthewavery"}}