{"action":"created","comment":{"url":"https://api.github.com/repos/hammerlab/varcode/pulls/comments/64833692","id":64833692,"diff_hunk":"@@ -174,48 +214,12 @@ def frameshift_coding_effect(\n             ref=ref,\n             alt=alt)\n     else:\n-        # special logic for insertions\n-        coding_sequence_after_insertion = \\\n-            sequence_from_start_codon[cds_offset + 1:]\n-        if cds_offset % 3 == 2:\n-            # insertion happens after last nucleotide in a codon,\n-            # doesn't disrupt the existing codon from cds_offset-2 to cds_offset\n-            mutated_codon_index = int(cds_offset / 3) + 1\n-            sequence_from_mutated_codon = (\n-                alt + coding_sequence_after_insertion)\n-        elif cds_offset % 3 == 1:\n-            # insertion happens after 2nd nucleotide of a codon\n-            # codon positions:\n-            #   1) cds_offset - 1\n-            #   2) cds_offset\n-            #    <----- Insertsion\n-            #   3) cds_offset + 1\n-            mutated_codon_index = int(cds_offset / 3)\n-            nucleotides_before = sequence_from_start_codon[\n-                cds_offset - 1:cds_offset + 1]\n-            nucleotide_after = sequence_from_start_codon[cds_offset + 1]\n-            sequence_from_mutated_codon = (\n-                nucleotides_before +\n-                alt +\n-                nucleotide_after +","path":"varcode/frameshift_coding_effect.py","position":86,"original_position":86,"commit_id":"0443ea5d4968b483c1aabacb6a36d7f8157be9e9","original_commit_id":"0443ea5d4968b483c1aabacb6a36d7f8157be9e9","user":{"login":"tavinathanson","id":322932,"avatar_url":"https://avatars.githubusercontent.com/u/322932?v=3","gravatar_id":"","url":"https://api.github.com/users/tavinathanson","html_url":"https://github.com/tavinathanson","followers_url":"https://api.github.com/users/tavinathanson/followers","following_url":"https://api.github.com/users/tavinathanson/following{/other_user}","gists_url":"https://api.github.com/users/tavinathanson/gists{/gist_id}","starred_url":"https://api.github.com/users/tavinathanson/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/tavinathanson/subscriptions","organizations_url":"https://api.github.com/users/tavinathanson/orgs","repos_url":"https://api.github.com/users/tavinathanson/repos","events_url":"https://api.github.com/users/tavinathanson/events{/privacy}","received_events_url":"https://api.github.com/users/tavinathanson/received_events","type":"User","site_admin":false},"body":"For reference, this line is removed in the change.","created_at":"2016-05-26T22:43:05Z","updated_at":"2016-05-26T22:43:05Z","html_url":"https://github.com/hammerlab/varcode/pull/152#discussion_r64833692","pull_request_url":"https://api.github.com/repos/hammerlab/varcode/pulls/152","_links":{"self":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/comments/64833692"},"html":{"href":"https://github.com/hammerlab/varcode/pull/152#discussion_r64833692"},"pull_request":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/152"}}},"pull_request":{"url":"https://api.github.com/repos/hammerlab/varcode/pulls/152","id":71630971,"html_url":"https://github.com/hammerlab/varcode/pull/152","diff_url":"https://github.com/hammerlab/varcode/pull/152.diff","patch_url":"https://github.com/hammerlab/varcode/pull/152.patch","issue_url":"https://api.github.com/repos/hammerlab/varcode/issues/152","number":152,"state":"open","locked":false,"title":"Added unit tests for Klf6 frameshift, fix bug in frameshift translation","user":{"login":"iskandr","id":48441,"avatar_url":"https://avatars.githubusercontent.com/u/48441?v=3","gravatar_id":"","url":"https://api.github.com/users/iskandr","html_url":"https://github.com/iskandr","followers_url":"https://api.github.com/users/iskandr/followers","following_url":"https://api.github.com/users/iskandr/following{/other_user}","gists_url":"https://api.github.com/users/iskandr/gists{/gist_id}","starred_url":"https://api.github.com/users/iskandr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/iskandr/subscriptions","organizations_url":"https://api.github.com/users/iskandr/orgs","repos_url":"https://api.github.com/users/iskandr/repos","events_url":"https://api.github.com/users/iskandr/events{/privacy}","received_events_url":"https://api.github.com/users/iskandr/received_events","type":"User","site_admin":false},"body":"Found a scary bug in the `frameshift_coding_effect.py`. The logic for translating frameshifts was wrong for some cases, added unit tests and fix. \r\n\r\nFixes https://github.com/hammerlab/varcode/issues/151, https://github.com/hammerlab/topiary/issues/52\n\n<!-- Reviewable:start -->\n---\nThis change is [<img src=\"https://reviewable.io/review_button.svg\" height=\"35\" align=\"absmiddle\" alt=\"Reviewable\"/>](https://reviewable.io/reviews/hammerlab/varcode/152)\n<!-- Reviewable:end -->\n","created_at":"2016-05-26T21:54:21Z","updated_at":"2016-05-26T22:43:05Z","closed_at":null,"merged_at":null,"merge_commit_sha":"98a47e62fbd2e106765811cfa7058fc2c6e62b71","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/hammerlab/varcode/pulls/152/commits","review_comments_url":"https://api.github.com/repos/hammerlab/varcode/pulls/152/comments","review_comment_url":"https://api.github.com/repos/hammerlab/varcode/pulls/comments{/number}","comments_url":"https://api.github.com/repos/hammerlab/varcode/issues/152/comments","statuses_url":"https://api.github.com/repos/hammerlab/varcode/statuses/0443ea5d4968b483c1aabacb6a36d7f8157be9e9","head":{"label":"hammerlab:Klf6-mm10-frameshift-test","ref":"Klf6-mm10-frameshift-test","sha":"0443ea5d4968b483c1aabacb6a36d7f8157be9e9","user":{"login":"hammerlab","id":6563873,"avatar_url":"https://avatars.githubusercontent.com/u/6563873?v=3","gravatar_id":"","url":"https://api.github.com/users/hammerlab","html_url":"https://github.com/hammerlab","followers_url":"https://api.github.com/users/hammerlab/followers","following_url":"https://api.github.com/users/hammerlab/following{/other_user}","gists_url":"https://api.github.com/users/hammerlab/gists{/gist_id}","starred_url":"https://api.github.com/users/hammerlab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hammerlab/subscriptions","organizations_url":"https://api.github.com/users/hammerlab/orgs","repos_url":"https://api.github.com/users/hammerlab/repos","events_url":"https://api.github.com/users/hammerlab/events{/privacy}","received_events_url":"https://api.github.com/users/hammerlab/received_events","type":"Organization","site_admin":false},"repo":{"id":26663543,"name":"varcode","full_name":"hammerlab/varcode","owner":{"login":"hammerlab","id":6563873,"avatar_url":"https://avatars.githubusercontent.com/u/6563873?v=3","gravatar_id":"","url":"https://api.github.com/users/hammerlab","html_url":"https://github.com/hammerlab","followers_url":"https://api.github.com/users/hammerlab/followers","following_url":"https://api.github.com/users/hammerlab/following{/other_user}","gists_url":"https://api.github.com/users/hammerlab/gists{/gist_id}","starred_url":"https://api.github.com/users/hammerlab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hammerlab/subscriptions","organizations_url":"https://api.github.com/users/hammerlab/orgs","repos_url":"https://api.github.com/users/hammerlab/repos","events_url":"https://api.github.com/users/hammerlab/events{/privacy}","received_events_url":"https://api.github.com/users/hammerlab/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hammerlab/varcode","description":"Variant annotation in Python","fork":false,"url":"https://api.github.com/repos/hammerlab/varcode","forks_url":"https://api.github.com/repos/hammerlab/varcode/forks","keys_url":"https://api.github.com/repos/hammerlab/varcode/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hammerlab/varcode/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hammerlab/varcode/teams","hooks_url":"https://api.github.com/repos/hammerlab/varcode/hooks","issue_events_url":"https://api.github.com/repos/hammerlab/varcode/issues/events{/number}","events_url":"https://api.github.com/repos/hammerlab/varcode/events","assignees_url":"https://api.github.com/repos/hammerlab/varcode/assignees{/user}","branches_url":"https://api.github.com/repos/hammerlab/varcode/branches{/branch}","tags_url":"https://api.github.com/repos/hammerlab/varcode/tags","blobs_url":"https://api.github.com/repos/hammerlab/varcode/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hammerlab/varcode/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hammerlab/varcode/git/refs{/sha}","trees_url":"https://api.github.com/repos/hammerlab/varcode/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hammerlab/varcode/statuses/{sha}","languages_url":"https://api.github.com/repos/hammerlab/varcode/languages","stargazers_url":"https://api.github.com/repos/hammerlab/varcode/stargazers","contributors_url":"https://api.github.com/repos/hammerlab/varcode/contributors","subscribers_url":"https://api.github.com/repos/hammerlab/varcode/subscribers","subscription_url":"https://api.github.com/repos/hammerlab/varcode/subscription","commits_url":"https://api.github.com/repos/hammerlab/varcode/commits{/sha}","git_commits_url":"https://api.github.com/repos/hammerlab/varcode/git/commits{/sha}","comments_url":"https://api.github.com/repos/hammerlab/varcode/comments{/number}","issue_comment_url":"https://api.github.com/repos/hammerlab/varcode/issues/comments{/number}","contents_url":"https://api.github.com/repos/hammerlab/varcode/contents/{+path}","compare_url":"https://api.github.com/repos/hammerlab/varcode/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hammerlab/varcode/merges","archive_url":"https://api.github.com/repos/hammerlab/varcode/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hammerlab/varcode/downloads","issues_url":"https://api.github.com/repos/hammerlab/varcode/issues{/number}","pulls_url":"https://api.github.com/repos/hammerlab/varcode/pulls{/number}","milestones_url":"https://api.github.com/repos/hammerlab/varcode/milestones{/number}","notifications_url":"https://api.github.com/repos/hammerlab/varcode/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hammerlab/varcode/labels{/name}","releases_url":"https://api.github.com/repos/hammerlab/varcode/releases{/id}","deployments_url":"https://api.github.com/repos/hammerlab/varcode/deployments","created_at":"2014-11-15T00:20:42Z","updated_at":"2016-05-06T12:36:06Z","pushed_at":"2016-05-26T22:40:19Z","git_url":"git://github.com/hammerlab/varcode.git","ssh_url":"git@github.com:hammerlab/varcode.git","clone_url":"https://github.com/hammerlab/varcode.git","svn_url":"https://github.com/hammerlab/varcode","homepage":null,"size":3961,"stargazers_count":25,"watchers_count":25,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":32,"forks":2,"open_issues":32,"watchers":25,"default_branch":"master"}},"base":{"label":"hammerlab:master","ref":"master","sha":"68033557977331accb66ac7cca67ffd408c622a7","user":{"login":"hammerlab","id":6563873,"avatar_url":"https://avatars.githubusercontent.com/u/6563873?v=3","gravatar_id":"","url":"https://api.github.com/users/hammerlab","html_url":"https://github.com/hammerlab","followers_url":"https://api.github.com/users/hammerlab/followers","following_url":"https://api.github.com/users/hammerlab/following{/other_user}","gists_url":"https://api.github.com/users/hammerlab/gists{/gist_id}","starred_url":"https://api.github.com/users/hammerlab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hammerlab/subscriptions","organizations_url":"https://api.github.com/users/hammerlab/orgs","repos_url":"https://api.github.com/users/hammerlab/repos","events_url":"https://api.github.com/users/hammerlab/events{/privacy}","received_events_url":"https://api.github.com/users/hammerlab/received_events","type":"Organization","site_admin":false},"repo":{"id":26663543,"name":"varcode","full_name":"hammerlab/varcode","owner":{"login":"hammerlab","id":6563873,"avatar_url":"https://avatars.githubusercontent.com/u/6563873?v=3","gravatar_id":"","url":"https://api.github.com/users/hammerlab","html_url":"https://github.com/hammerlab","followers_url":"https://api.github.com/users/hammerlab/followers","following_url":"https://api.github.com/users/hammerlab/following{/other_user}","gists_url":"https://api.github.com/users/hammerlab/gists{/gist_id}","starred_url":"https://api.github.com/users/hammerlab/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hammerlab/subscriptions","organizations_url":"https://api.github.com/users/hammerlab/orgs","repos_url":"https://api.github.com/users/hammerlab/repos","events_url":"https://api.github.com/users/hammerlab/events{/privacy}","received_events_url":"https://api.github.com/users/hammerlab/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/hammerlab/varcode","description":"Variant annotation in Python","fork":false,"url":"https://api.github.com/repos/hammerlab/varcode","forks_url":"https://api.github.com/repos/hammerlab/varcode/forks","keys_url":"https://api.github.com/repos/hammerlab/varcode/keys{/key_id}","collaborators_url":"https://api.github.com/repos/hammerlab/varcode/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/hammerlab/varcode/teams","hooks_url":"https://api.github.com/repos/hammerlab/varcode/hooks","issue_events_url":"https://api.github.com/repos/hammerlab/varcode/issues/events{/number}","events_url":"https://api.github.com/repos/hammerlab/varcode/events","assignees_url":"https://api.github.com/repos/hammerlab/varcode/assignees{/user}","branches_url":"https://api.github.com/repos/hammerlab/varcode/branches{/branch}","tags_url":"https://api.github.com/repos/hammerlab/varcode/tags","blobs_url":"https://api.github.com/repos/hammerlab/varcode/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/hammerlab/varcode/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/hammerlab/varcode/git/refs{/sha}","trees_url":"https://api.github.com/repos/hammerlab/varcode/git/trees{/sha}","statuses_url":"https://api.github.com/repos/hammerlab/varcode/statuses/{sha}","languages_url":"https://api.github.com/repos/hammerlab/varcode/languages","stargazers_url":"https://api.github.com/repos/hammerlab/varcode/stargazers","contributors_url":"https://api.github.com/repos/hammerlab/varcode/contributors","subscribers_url":"https://api.github.com/repos/hammerlab/varcode/subscribers","subscription_url":"https://api.github.com/repos/hammerlab/varcode/subscription","commits_url":"https://api.github.com/repos/hammerlab/varcode/commits{/sha}","git_commits_url":"https://api.github.com/repos/hammerlab/varcode/git/commits{/sha}","comments_url":"https://api.github.com/repos/hammerlab/varcode/comments{/number}","issue_comment_url":"https://api.github.com/repos/hammerlab/varcode/issues/comments{/number}","contents_url":"https://api.github.com/repos/hammerlab/varcode/contents/{+path}","compare_url":"https://api.github.com/repos/hammerlab/varcode/compare/{base}...{head}","merges_url":"https://api.github.com/repos/hammerlab/varcode/merges","archive_url":"https://api.github.com/repos/hammerlab/varcode/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/hammerlab/varcode/downloads","issues_url":"https://api.github.com/repos/hammerlab/varcode/issues{/number}","pulls_url":"https://api.github.com/repos/hammerlab/varcode/pulls{/number}","milestones_url":"https://api.github.com/repos/hammerlab/varcode/milestones{/number}","notifications_url":"https://api.github.com/repos/hammerlab/varcode/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/hammerlab/varcode/labels{/name}","releases_url":"https://api.github.com/repos/hammerlab/varcode/releases{/id}","deployments_url":"https://api.github.com/repos/hammerlab/varcode/deployments","created_at":"2014-11-15T00:20:42Z","updated_at":"2016-05-06T12:36:06Z","pushed_at":"2016-05-26T22:40:19Z","git_url":"git://github.com/hammerlab/varcode.git","ssh_url":"git@github.com:hammerlab/varcode.git","clone_url":"https://github.com/hammerlab/varcode.git","svn_url":"https://github.com/hammerlab/varcode","homepage":null,"size":3961,"stargazers_count":25,"watchers_count":25,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":2,"mirror_url":null,"open_issues_count":32,"forks":2,"open_issues":32,"watchers":25,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/152"},"html":{"href":"https://github.com/hammerlab/varcode/pull/152"},"issue":{"href":"https://api.github.com/repos/hammerlab/varcode/issues/152"},"comments":{"href":"https://api.github.com/repos/hammerlab/varcode/issues/152/comments"},"review_comments":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/152/comments"},"review_comment":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/hammerlab/varcode/pulls/152/commits"},"statuses":{"href":"https://api.github.com/repos/hammerlab/varcode/statuses/0443ea5d4968b483c1aabacb6a36d7f8157be9e9"}}}}
{"actor":{"display_login":"tavinathanson"}}