{"action":"created","comment":{"url":"https://api.github.com/repos/travnick/CryBlend/pulls/comments/56970578","id":56970578,"diff_hunk":"@@ -721,10 +721,17 @@ def add_fakebones():\n \r\n def remove_fakebones():\r\n     '''Select to remove all fakebones from the scene.'''\r\n+    if len(get_type(\"fakebones\")) == 0:\r\n+        return        \r\n+    old_mode = bpy.context.mode\r\n+    if old_mode != 'OBJECT':\r\n+        bpy.ops.object.mode_set(mode='OBJECT')\r\n     deselect_all()\r\n     for fakebone in get_type(\"fakebones\"):\r\n         fakebone.select = True\r\n         bpy.ops.object.delete(use_global=False)\r\n+    if old_mode != 'OBJECT':\r\n+        bpy.ops.object.mode_set(mode=old_mode)\r","path":"io_export_cryblend/utils.py","position":41,"original_position":41,"commit_id":"998659b0aba97ce94204e0f582b2b7ed6f5d25e0","original_commit_id":"998659b0aba97ce94204e0f582b2b7ed6f5d25e0","user":{"login":"ochounos","id":7502581,"avatar_url":"https://avatars.githubusercontent.com/u/7502581?v=3","gravatar_id":"","url":"https://api.github.com/users/ochounos","html_url":"https://github.com/ochounos","followers_url":"https://api.github.com/users/ochounos/followers","following_url":"https://api.github.com/users/ochounos/following{/other_user}","gists_url":"https://api.github.com/users/ochounos/gists{/gist_id}","starred_url":"https://api.github.com/users/ochounos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ochounos/subscriptions","organizations_url":"https://api.github.com/users/ochounos/orgs","repos_url":"https://api.github.com/users/ochounos/repos","events_url":"https://api.github.com/users/ochounos/events{/privacy}","received_events_url":"https://api.github.com/users/ochounos/received_events","type":"User","site_admin":false},"body":"When you are in pose mode, if you try to export fails because the context is not valid when try to delete elements. Movind to OBJECT mode makes it work.","created_at":"2016-03-22T11:23:42Z","updated_at":"2016-03-22T11:23:42Z","html_url":"https://github.com/travnick/CryBlend/pull/181#discussion_r56970578","pull_request_url":"https://api.github.com/repos/travnick/CryBlend/pulls/181","_links":{"self":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/comments/56970578"},"html":{"href":"https://github.com/travnick/CryBlend/pull/181#discussion_r56970578"},"pull_request":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/181"}}},"pull_request":{"url":"https://api.github.com/repos/travnick/CryBlend/pulls/181","id":63703458,"html_url":"https://github.com/travnick/CryBlend/pull/181","diff_url":"https://github.com/travnick/CryBlend/pull/181.diff","patch_url":"https://github.com/travnick/CryBlend/pull/181.patch","issue_url":"https://api.github.com/repos/travnick/CryBlend/issues/181","number":181,"state":"open","locked":false,"title":"Fix vertex groups not assigned to bones","user":{"login":"ochounos","id":7502581,"avatar_url":"https://avatars.githubusercontent.com/u/7502581?v=3","gravatar_id":"","url":"https://api.github.com/users/ochounos","html_url":"https://github.com/ochounos","followers_url":"https://api.github.com/users/ochounos/followers","following_url":"https://api.github.com/users/ochounos/following{/other_user}","gists_url":"https://api.github.com/users/ochounos/gists{/gist_id}","starred_url":"https://api.github.com/users/ochounos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ochounos/subscriptions","organizations_url":"https://api.github.com/users/ochounos/orgs","repos_url":"https://api.github.com/users/ochounos/repos","events_url":"https://api.github.com/users/ochounos/events{/privacy}","received_events_url":"https://api.github.com/users/ochounos/received_events","type":"User","site_admin":false},"body":"Weights are assigned via vertex group name and bone name association. This patch fixes when there are vertex groups named not matching any bone. Also improve speed of weights generation and limits to 8 bones references per vertex.","created_at":"2016-03-22T11:14:58Z","updated_at":"2016-03-22T11:23:42Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d9df9c2cafaa6ea1d0054c2109c3a5014e7c7256","assignee":null,"milestone":{"url":"https://api.github.com/repos/travnick/CryBlend/milestones/9","html_url":"https://github.com/travnick/CryBlend/milestones/5.10","labels_url":"https://api.github.com/repos/travnick/CryBlend/milestones/9/labels","id":957815,"number":9,"title":"5.10","description":"Focus on bug fixes and improving general robustness of code.","creator":{"login":"dwhite4","id":6201009,"avatar_url":"https://avatars.githubusercontent.com/u/6201009?v=3","gravatar_id":"","url":"https://api.github.com/users/dwhite4","html_url":"https://github.com/dwhite4","followers_url":"https://api.github.com/users/dwhite4/followers","following_url":"https://api.github.com/users/dwhite4/following{/other_user}","gists_url":"https://api.github.com/users/dwhite4/gists{/gist_id}","starred_url":"https://api.github.com/users/dwhite4/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/dwhite4/subscriptions","organizations_url":"https://api.github.com/users/dwhite4/orgs","repos_url":"https://api.github.com/users/dwhite4/repos","events_url":"https://api.github.com/users/dwhite4/events{/privacy}","received_events_url":"https://api.github.com/users/dwhite4/received_events","type":"User","site_admin":false},"open_issues":5,"closed_issues":28,"state":"open","created_at":"2015-01-30T03:55:32Z","updated_at":"2016-03-22T11:15:59Z","due_on":"2016-03-31T21:00:00Z","closed_at":null},"commits_url":"https://api.github.com/repos/travnick/CryBlend/pulls/181/commits","review_comments_url":"https://api.github.com/repos/travnick/CryBlend/pulls/181/comments","review_comment_url":"https://api.github.com/repos/travnick/CryBlend/pulls/comments{/number}","comments_url":"https://api.github.com/repos/travnick/CryBlend/issues/181/comments","statuses_url":"https://api.github.com/repos/travnick/CryBlend/statuses/998659b0aba97ce94204e0f582b2b7ed6f5d25e0","head":{"label":"ochounos:fix_vertex_group","ref":"fix_vertex_group","sha":"998659b0aba97ce94204e0f582b2b7ed6f5d25e0","user":{"login":"ochounos","id":7502581,"avatar_url":"https://avatars.githubusercontent.com/u/7502581?v=3","gravatar_id":"","url":"https://api.github.com/users/ochounos","html_url":"https://github.com/ochounos","followers_url":"https://api.github.com/users/ochounos/followers","following_url":"https://api.github.com/users/ochounos/following{/other_user}","gists_url":"https://api.github.com/users/ochounos/gists{/gist_id}","starred_url":"https://api.github.com/users/ochounos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ochounos/subscriptions","organizations_url":"https://api.github.com/users/ochounos/orgs","repos_url":"https://api.github.com/users/ochounos/repos","events_url":"https://api.github.com/users/ochounos/events{/privacy}","received_events_url":"https://api.github.com/users/ochounos/received_events","type":"User","site_admin":false},"repo":{"id":52308746,"name":"CryBlend","full_name":"ochounos/CryBlend","owner":{"login":"ochounos","id":7502581,"avatar_url":"https://avatars.githubusercontent.com/u/7502581?v=3","gravatar_id":"","url":"https://api.github.com/users/ochounos","html_url":"https://github.com/ochounos","followers_url":"https://api.github.com/users/ochounos/followers","following_url":"https://api.github.com/users/ochounos/following{/other_user}","gists_url":"https://api.github.com/users/ochounos/gists{/gist_id}","starred_url":"https://api.github.com/users/ochounos/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ochounos/subscriptions","organizations_url":"https://api.github.com/users/ochounos/orgs","repos_url":"https://api.github.com/users/ochounos/repos","events_url":"https://api.github.com/users/ochounos/events{/privacy}","received_events_url":"https://api.github.com/users/ochounos/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/ochounos/CryBlend","description":"CryEngine3 Utilities and Exporter for Blender","fork":true,"url":"https://api.github.com/repos/ochounos/CryBlend","forks_url":"https://api.github.com/repos/ochounos/CryBlend/forks","keys_url":"https://api.github.com/repos/ochounos/CryBlend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/ochounos/CryBlend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/ochounos/CryBlend/teams","hooks_url":"https://api.github.com/repos/ochounos/CryBlend/hooks","issue_events_url":"https://api.github.com/repos/ochounos/CryBlend/issues/events{/number}","events_url":"https://api.github.com/repos/ochounos/CryBlend/events","assignees_url":"https://api.github.com/repos/ochounos/CryBlend/assignees{/user}","branches_url":"https://api.github.com/repos/ochounos/CryBlend/branches{/branch}","tags_url":"https://api.github.com/repos/ochounos/CryBlend/tags","blobs_url":"https://api.github.com/repos/ochounos/CryBlend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/ochounos/CryBlend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/ochounos/CryBlend/git/refs{/sha}","trees_url":"https://api.github.com/repos/ochounos/CryBlend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/ochounos/CryBlend/statuses/{sha}","languages_url":"https://api.github.com/repos/ochounos/CryBlend/languages","stargazers_url":"https://api.github.com/repos/ochounos/CryBlend/stargazers","contributors_url":"https://api.github.com/repos/ochounos/CryBlend/contributors","subscribers_url":"https://api.github.com/repos/ochounos/CryBlend/subscribers","subscription_url":"https://api.github.com/repos/ochounos/CryBlend/subscription","commits_url":"https://api.github.com/repos/ochounos/CryBlend/commits{/sha}","git_commits_url":"https://api.github.com/repos/ochounos/CryBlend/git/commits{/sha}","comments_url":"https://api.github.com/repos/ochounos/CryBlend/comments{/number}","issue_comment_url":"https://api.github.com/repos/ochounos/CryBlend/issues/comments{/number}","contents_url":"https://api.github.com/repos/ochounos/CryBlend/contents/{+path}","compare_url":"https://api.github.com/repos/ochounos/CryBlend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/ochounos/CryBlend/merges","archive_url":"https://api.github.com/repos/ochounos/CryBlend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/ochounos/CryBlend/downloads","issues_url":"https://api.github.com/repos/ochounos/CryBlend/issues{/number}","pulls_url":"https://api.github.com/repos/ochounos/CryBlend/pulls{/number}","milestones_url":"https://api.github.com/repos/ochounos/CryBlend/milestones{/number}","notifications_url":"https://api.github.com/repos/ochounos/CryBlend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/ochounos/CryBlend/labels{/name}","releases_url":"https://api.github.com/repos/ochounos/CryBlend/releases{/id}","deployments_url":"https://api.github.com/repos/ochounos/CryBlend/deployments","created_at":"2016-02-22T21:54:12Z","updated_at":"2016-03-19T06:07:01Z","pushed_at":"2016-03-22T11:13:27Z","git_url":"git://github.com/ochounos/CryBlend.git","ssh_url":"git@github.com:ochounos/CryBlend.git","clone_url":"https://github.com/ochounos/CryBlend.git","svn_url":"https://github.com/ochounos/CryBlend","homepage":"http://travnick.github.io/CryBlend/","size":1410,"stargazers_count":1,"watchers_count":1,"language":"Python","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":1,"default_branch":"ochounos"}},"base":{"label":"travnick:develop","ref":"develop","sha":"717fe1df7921ee377142448a873559873be83404","user":{"login":"travnick","id":619590,"avatar_url":"https://avatars.githubusercontent.com/u/619590?v=3","gravatar_id":"","url":"https://api.github.com/users/travnick","html_url":"https://github.com/travnick","followers_url":"https://api.github.com/users/travnick/followers","following_url":"https://api.github.com/users/travnick/following{/other_user}","gists_url":"https://api.github.com/users/travnick/gists{/gist_id}","starred_url":"https://api.github.com/users/travnick/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/travnick/subscriptions","organizations_url":"https://api.github.com/users/travnick/orgs","repos_url":"https://api.github.com/users/travnick/repos","events_url":"https://api.github.com/users/travnick/events{/privacy}","received_events_url":"https://api.github.com/users/travnick/received_events","type":"User","site_admin":false},"repo":{"id":10533169,"name":"CryBlend","full_name":"travnick/CryBlend","owner":{"login":"travnick","id":619590,"avatar_url":"https://avatars.githubusercontent.com/u/619590?v=3","gravatar_id":"","url":"https://api.github.com/users/travnick","html_url":"https://github.com/travnick","followers_url":"https://api.github.com/users/travnick/followers","following_url":"https://api.github.com/users/travnick/following{/other_user}","gists_url":"https://api.github.com/users/travnick/gists{/gist_id}","starred_url":"https://api.github.com/users/travnick/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/travnick/subscriptions","organizations_url":"https://api.github.com/users/travnick/orgs","repos_url":"https://api.github.com/users/travnick/repos","events_url":"https://api.github.com/users/travnick/events{/privacy}","received_events_url":"https://api.github.com/users/travnick/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/travnick/CryBlend","description":"CryEngine3 Utilities and Exporter for Blender","fork":false,"url":"https://api.github.com/repos/travnick/CryBlend","forks_url":"https://api.github.com/repos/travnick/CryBlend/forks","keys_url":"https://api.github.com/repos/travnick/CryBlend/keys{/key_id}","collaborators_url":"https://api.github.com/repos/travnick/CryBlend/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/travnick/CryBlend/teams","hooks_url":"https://api.github.com/repos/travnick/CryBlend/hooks","issue_events_url":"https://api.github.com/repos/travnick/CryBlend/issues/events{/number}","events_url":"https://api.github.com/repos/travnick/CryBlend/events","assignees_url":"https://api.github.com/repos/travnick/CryBlend/assignees{/user}","branches_url":"https://api.github.com/repos/travnick/CryBlend/branches{/branch}","tags_url":"https://api.github.com/repos/travnick/CryBlend/tags","blobs_url":"https://api.github.com/repos/travnick/CryBlend/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/travnick/CryBlend/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/travnick/CryBlend/git/refs{/sha}","trees_url":"https://api.github.com/repos/travnick/CryBlend/git/trees{/sha}","statuses_url":"https://api.github.com/repos/travnick/CryBlend/statuses/{sha}","languages_url":"https://api.github.com/repos/travnick/CryBlend/languages","stargazers_url":"https://api.github.com/repos/travnick/CryBlend/stargazers","contributors_url":"https://api.github.com/repos/travnick/CryBlend/contributors","subscribers_url":"https://api.github.com/repos/travnick/CryBlend/subscribers","subscription_url":"https://api.github.com/repos/travnick/CryBlend/subscription","commits_url":"https://api.github.com/repos/travnick/CryBlend/commits{/sha}","git_commits_url":"https://api.github.com/repos/travnick/CryBlend/git/commits{/sha}","comments_url":"https://api.github.com/repos/travnick/CryBlend/comments{/number}","issue_comment_url":"https://api.github.com/repos/travnick/CryBlend/issues/comments{/number}","contents_url":"https://api.github.com/repos/travnick/CryBlend/contents/{+path}","compare_url":"https://api.github.com/repos/travnick/CryBlend/compare/{base}...{head}","merges_url":"https://api.github.com/repos/travnick/CryBlend/merges","archive_url":"https://api.github.com/repos/travnick/CryBlend/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/travnick/CryBlend/downloads","issues_url":"https://api.github.com/repos/travnick/CryBlend/issues{/number}","pulls_url":"https://api.github.com/repos/travnick/CryBlend/pulls{/number}","milestones_url":"https://api.github.com/repos/travnick/CryBlend/milestones{/number}","notifications_url":"https://api.github.com/repos/travnick/CryBlend/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/travnick/CryBlend/labels{/name}","releases_url":"https://api.github.com/repos/travnick/CryBlend/releases{/id}","deployments_url":"https://api.github.com/repos/travnick/CryBlend/deployments","created_at":"2013-06-06T18:18:55Z","updated_at":"2016-03-20T18:51:28Z","pushed_at":"2016-03-22T11:14:59Z","git_url":"git://github.com/travnick/CryBlend.git","ssh_url":"git@github.com:travnick/CryBlend.git","clone_url":"https://github.com/travnick/CryBlend.git","svn_url":"https://github.com/travnick/CryBlend","homepage":"http://travnick.github.io/CryBlend/","size":2295,"stargazers_count":53,"watchers_count":53,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":13,"mirror_url":null,"open_issues_count":15,"forks":13,"open_issues":15,"watchers":53,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/181"},"html":{"href":"https://github.com/travnick/CryBlend/pull/181"},"issue":{"href":"https://api.github.com/repos/travnick/CryBlend/issues/181"},"comments":{"href":"https://api.github.com/repos/travnick/CryBlend/issues/181/comments"},"review_comments":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/181/comments"},"review_comment":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/travnick/CryBlend/pulls/181/commits"},"statuses":{"href":"https://api.github.com/repos/travnick/CryBlend/statuses/998659b0aba97ce94204e0f582b2b7ed6f5d25e0"}}}}