GitHub PullRequestReviewCommentEvent at 2014-11-30 00:58:32
Repository: Markus
Actor: houndci
Payload: {"action":"created","comment":{"url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/21057477","id":21057477,"diff_hunk":"@@ -177,34 +177,53 @@ class SubmissionsController < ApplicationController\n       'none' => {\n         display: I18n.t('browse_submissions.show_all'),\n         proc: lambda { |params, to_include|\n-          params[:assignment].groupings.all(include: to_include)}},\n+          params[:assignment].groupings.includes(to_include)\n+        }\n+      },\n       'unmarked' => {\n         display: I18n.t('browse_submissions.show_unmarked'),\n         proc: lambda { |params, to_include|\n-          params[:assignment].groupings.all(include: [to_include]).\n-              select{|g| !g.has_submission? || (g.has_submission? &&\n-              g.current_submission_used.get_latest_result.marking_state ==\n-                  Result::MARKING_STATES[:unmarked]) } }},\n+          params[:assignment].groupings.includes([to_include])\n+                             .select{ |g| !g.has_submission? ||\n+                                      (g.has_submission? &&\n+                                       g.current_submission_used\n+                                       .get_latest_result.marking_state ==\n+                                       Result::MARKING_STATES[:unmarked])\n+                              }\n+        }\n+      },\n       'partial' => {\n         display: I18n.t('browse_submissions.show_partial'),\n         proc: lambda { |params, to_include|\n-          params[:assignment].groupings.all(include: [to_include]).\n-              select{|g| g.has_submission? &&\n-              g.current_submission_used.get_latest_result.marking_state ==\n-                  Result::MARKING_STATES[:partial] } }},\n+          params[:assignment].groupings.includes([to_include])\n+                             .select{ |g| g.has_submission? &&\n+                                      g.current_submission_used\n+                                      .get_latest_result.marking_state ==\n+                                      Result::MARKING_STATES[:partial]\n+                              }","path":"app/controllers/submissions_controller.rb","position":36,"original_position":36,"commit_id":"e452b59857265f785aaf927368119145b1c559f1","original_commit_id":"e452b59857265f785aaf927368119145b1c559f1","user":{"login":"houndci","id":6697940,"avatar_url":"https://avatars.githubusercontent.com/u/6697940?v=3","gravatar_id":"","url":"https://api.github.com/users/houndci","html_url":"https://github.com/houndci","followers_url":"https://api.github.com/users/houndci/followers","following_url":"https://api.github.com/users/houndci/following{/other_user}","gists_url":"https://api.github.com/users/houndci/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci/subscriptions","organizations_url":"https://api.github.com/users/houndci/orgs","repos_url":"https://api.github.com/users/houndci/repos","events_url":"https://api.github.com/users/houndci/events{/privacy}","received_events_url":"https://api.github.com/users/houndci/received_events","type":"User","site_admin":false},"body":"`end` at 203, 30 is not aligned with `params[:assignment].groupings.includes([to_include])` at 198, 10 or `.select{ |g| g.has_submission? &&` at 199, 29","created_at":"2014-11-30T00:58:32Z","updated_at":"2014-11-30T00:58:32Z","html_url":"https://github.com/MarkUsProject/Markus/pull/1913#discussion_r21057477","pull_request_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913","_links":{"self":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/21057477"},"html":{"href":"https://github.com/MarkUsProject/Markus/pull/1913#discussion_r21057477"},"pull_request":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913"}}},"pull_request":{"url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913","id":25228904,"html_url":"https://github.com/MarkUsProject/Markus/pull/1913","diff_url":"https://github.com/MarkUsProject/Markus/pull/1913.diff","patch_url":"https://github.com/MarkUsProject/Markus/pull/1913.patch","issue_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/1913","number":1913,"state":"open","locked":false,"title":"Update code related to Relation#all which has been removed from rails 4....","user":{"login":"YusiFan","id":1100855,"avatar_url":"https://avatars.githubusercontent.com/u/1100855?v=3","gravatar_id":"","url":"https://api.github.com/users/YusiFan","html_url":"https://github.com/YusiFan","followers_url":"https://api.github.com/users/YusiFan/followers","following_url":"https://api.github.com/users/YusiFan/following{/other_user}","gists_url":"https://api.github.com/users/YusiFan/gists{/gist_id}","starred_url":"https://api.github.com/users/YusiFan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/YusiFan/subscriptions","organizations_url":"https://api.github.com/users/YusiFan/orgs","repos_url":"https://api.github.com/users/YusiFan/repos","events_url":"https://api.github.com/users/YusiFan/events{/privacy}","received_events_url":"https://api.github.com/users/YusiFan/received_events","type":"User","site_admin":false},"body":"Update code related to Relation#all which has been removed from rails 4.1","created_at":"2014-11-30T00:01:45Z","updated_at":"2014-11-30T00:58:32Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d067ece524049d955d19b0bd65746f1b211279ea","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913/commits","review_comments_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913/comments","review_comment_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/{number}","comments_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/1913/comments","statuses_url":"https://api.github.com/repos/MarkUsProject/Markus/statuses/e452b59857265f785aaf927368119145b1c559f1","head":{"label":"YusiFan:rails4_new","ref":"rails4_new","sha":"e452b59857265f785aaf927368119145b1c559f1","user":{"login":"YusiFan","id":1100855,"avatar_url":"https://avatars.githubusercontent.com/u/1100855?v=3","gravatar_id":"","url":"https://api.github.com/users/YusiFan","html_url":"https://github.com/YusiFan","followers_url":"https://api.github.com/users/YusiFan/followers","following_url":"https://api.github.com/users/YusiFan/following{/other_user}","gists_url":"https://api.github.com/users/YusiFan/gists{/gist_id}","starred_url":"https://api.github.com/users/YusiFan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/YusiFan/subscriptions","organizations_url":"https://api.github.com/users/YusiFan/orgs","repos_url":"https://api.github.com/users/YusiFan/repos","events_url":"https://api.github.com/users/YusiFan/events{/privacy}","received_events_url":"https://api.github.com/users/YusiFan/received_events","type":"User","site_admin":false},"repo":{"id":23925968,"name":"Markus","full_name":"YusiFan/Markus","owner":{"login":"YusiFan","id":1100855,"avatar_url":"https://avatars.githubusercontent.com/u/1100855?v=3","gravatar_id":"","url":"https://api.github.com/users/YusiFan","html_url":"https://github.com/YusiFan","followers_url":"https://api.github.com/users/YusiFan/followers","following_url":"https://api.github.com/users/YusiFan/following{/other_user}","gists_url":"https://api.github.com/users/YusiFan/gists{/gist_id}","starred_url":"https://api.github.com/users/YusiFan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/YusiFan/subscriptions","organizations_url":"https://api.github.com/users/YusiFan/orgs","repos_url":"https://api.github.com/users/YusiFan/repos","events_url":"https://api.github.com/users/YusiFan/events{/privacy}","received_events_url":"https://api.github.com/users/YusiFan/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/YusiFan/Markus","description":"Git repository of MarkUs","fork":true,"url":"https://api.github.com/repos/YusiFan/Markus","forks_url":"https://api.github.com/repos/YusiFan/Markus/forks","keys_url":"https://api.github.com/repos/YusiFan/Markus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/YusiFan/Markus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/YusiFan/Markus/teams","hooks_url":"https://api.github.com/repos/YusiFan/Markus/hooks","issue_events_url":"https://api.github.com/repos/YusiFan/Markus/issues/events{/number}","events_url":"https://api.github.com/repos/YusiFan/Markus/events","assignees_url":"https://api.github.com/repos/YusiFan/Markus/assignees{/user}","branches_url":"https://api.github.com/repos/YusiFan/Markus/branches{/branch}","tags_url":"https://api.github.com/repos/YusiFan/Markus/tags","blobs_url":"https://api.github.com/repos/YusiFan/Markus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/YusiFan/Markus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/YusiFan/Markus/git/refs{/sha}","trees_url":"https://api.github.com/repos/YusiFan/Markus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/YusiFan/Markus/statuses/{sha}","languages_url":"https://api.github.com/repos/YusiFan/Markus/languages","stargazers_url":"https://api.github.com/repos/YusiFan/Markus/stargazers","contributors_url":"https://api.github.com/repos/YusiFan/Markus/contributors","subscribers_url":"https://api.github.com/repos/YusiFan/Markus/subscribers","subscription_url":"https://api.github.com/repos/YusiFan/Markus/subscription","commits_url":"https://api.github.com/repos/YusiFan/Markus/commits{/sha}","git_commits_url":"https://api.github.com/repos/YusiFan/Markus/git/commits{/sha}","comments_url":"https://api.github.com/repos/YusiFan/Markus/comments{/number}","issue_comment_url":"https://api.github.com/repos/YusiFan/Markus/issues/comments/{number}","contents_url":"https://api.github.com/repos/YusiFan/Markus/contents/{+path}","compare_url":"https://api.github.com/repos/YusiFan/Markus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/YusiFan/Markus/merges","archive_url":"https://api.github.com/repos/YusiFan/Markus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/YusiFan/Markus/downloads","issues_url":"https://api.github.com/repos/YusiFan/Markus/issues{/number}","pulls_url":"https://api.github.com/repos/YusiFan/Markus/pulls{/number}","milestones_url":"https://api.github.com/repos/YusiFan/Markus/milestones{/number}","notifications_url":"https://api.github.com/repos/YusiFan/Markus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/YusiFan/Markus/labels{/name}","releases_url":"https://api.github.com/repos/YusiFan/Markus/releases{/id}","created_at":"2014-09-11T16:21:17Z","updated_at":"2014-11-24T23:03:11Z","pushed_at":"2014-11-30T00:58:23Z","git_url":"git://github.com/YusiFan/Markus.git","ssh_url":"git@github.com:YusiFan/Markus.git","clone_url":"https://github.com/YusiFan/Markus.git","svn_url":"https://github.com/YusiFan/Markus","homepage":"http://www.markusproject.org","size":17655,"stargazers_count":0,"watchers_count":0,"language":"Ruby","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":"MarkUsProject:rails4","ref":"rails4","sha":"036da41e7cb71c363cabf2acfe0167862530c21a","user":{"login":"MarkUsProject","id":415874,"avatar_url":"https://avatars.githubusercontent.com/u/415874?v=3","gravatar_id":"","url":"https://api.github.com/users/MarkUsProject","html_url":"https://github.com/MarkUsProject","followers_url":"https://api.github.com/users/MarkUsProject/followers","following_url":"https://api.github.com/users/MarkUsProject/following{/other_user}","gists_url":"https://api.github.com/users/MarkUsProject/gists{/gist_id}","starred_url":"https://api.github.com/users/MarkUsProject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarkUsProject/subscriptions","organizations_url":"https://api.github.com/users/MarkUsProject/orgs","repos_url":"https://api.github.com/users/MarkUsProject/repos","events_url":"https://api.github.com/users/MarkUsProject/events{/privacy}","received_events_url":"https://api.github.com/users/MarkUsProject/received_events","type":"Organization","site_admin":false},"repo":{"id":940538,"name":"Markus","full_name":"MarkUsProject/Markus","owner":{"login":"MarkUsProject","id":415874,"avatar_url":"https://avatars.githubusercontent.com/u/415874?v=3","gravatar_id":"","url":"https://api.github.com/users/MarkUsProject","html_url":"https://github.com/MarkUsProject","followers_url":"https://api.github.com/users/MarkUsProject/followers","following_url":"https://api.github.com/users/MarkUsProject/following{/other_user}","gists_url":"https://api.github.com/users/MarkUsProject/gists{/gist_id}","starred_url":"https://api.github.com/users/MarkUsProject/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/MarkUsProject/subscriptions","organizations_url":"https://api.github.com/users/MarkUsProject/orgs","repos_url":"https://api.github.com/users/MarkUsProject/repos","events_url":"https://api.github.com/users/MarkUsProject/events{/privacy}","received_events_url":"https://api.github.com/users/MarkUsProject/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/MarkUsProject/Markus","description":"Git repository of MarkUs","fork":false,"url":"https://api.github.com/repos/MarkUsProject/Markus","forks_url":"https://api.github.com/repos/MarkUsProject/Markus/forks","keys_url":"https://api.github.com/repos/MarkUsProject/Markus/keys{/key_id}","collaborators_url":"https://api.github.com/repos/MarkUsProject/Markus/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/MarkUsProject/Markus/teams","hooks_url":"https://api.github.com/repos/MarkUsProject/Markus/hooks","issue_events_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/events{/number}","events_url":"https://api.github.com/repos/MarkUsProject/Markus/events","assignees_url":"https://api.github.com/repos/MarkUsProject/Markus/assignees{/user}","branches_url":"https://api.github.com/repos/MarkUsProject/Markus/branches{/branch}","tags_url":"https://api.github.com/repos/MarkUsProject/Markus/tags","blobs_url":"https://api.github.com/repos/MarkUsProject/Markus/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/MarkUsProject/Markus/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/MarkUsProject/Markus/git/refs{/sha}","trees_url":"https://api.github.com/repos/MarkUsProject/Markus/git/trees{/sha}","statuses_url":"https://api.github.com/repos/MarkUsProject/Markus/statuses/{sha}","languages_url":"https://api.github.com/repos/MarkUsProject/Markus/languages","stargazers_url":"https://api.github.com/repos/MarkUsProject/Markus/stargazers","contributors_url":"https://api.github.com/repos/MarkUsProject/Markus/contributors","subscribers_url":"https://api.github.com/repos/MarkUsProject/Markus/subscribers","subscription_url":"https://api.github.com/repos/MarkUsProject/Markus/subscription","commits_url":"https://api.github.com/repos/MarkUsProject/Markus/commits{/sha}","git_commits_url":"https://api.github.com/repos/MarkUsProject/Markus/git/commits{/sha}","comments_url":"https://api.github.com/repos/MarkUsProject/Markus/comments{/number}","issue_comment_url":"https://api.github.com/repos/MarkUsProject/Markus/issues/comments/{number}","contents_url":"https://api.github.com/repos/MarkUsProject/Markus/contents/{+path}","compare_url":"https://api.github.com/repos/MarkUsProject/Markus/compare/{base}...{head}","merges_url":"https://api.github.com/repos/MarkUsProject/Markus/merges","archive_url":"https://api.github.com/repos/MarkUsProject/Markus/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/MarkUsProject/Markus/downloads","issues_url":"https://api.github.com/repos/MarkUsProject/Markus/issues{/number}","pulls_url":"https://api.github.com/repos/MarkUsProject/Markus/pulls{/number}","milestones_url":"https://api.github.com/repos/MarkUsProject/Markus/milestones{/number}","notifications_url":"https://api.github.com/repos/MarkUsProject/Markus/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/MarkUsProject/Markus/labels{/name}","releases_url":"https://api.github.com/repos/MarkUsProject/Markus/releases{/id}","created_at":"2010-09-26T16:18:08Z","updated_at":"2014-11-25T21:22:24Z","pushed_at":"2014-11-29T04:02:36Z","git_url":"git://github.com/MarkUsProject/Markus.git","ssh_url":"git@github.com:MarkUsProject/Markus.git","clone_url":"https://github.com/MarkUsProject/Markus.git","svn_url":"https://github.com/MarkUsProject/Markus","homepage":"http://www.markusproject.org","size":50443,"stargazers_count":114,"watchers_count":114,"language":"Ruby","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":133,"mirror_url":null,"open_issues_count":130,"forks":133,"open_issues":130,"watchers":114,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913"},"html":{"href":"https://github.com/MarkUsProject/Markus/pull/1913"},"issue":{"href":"https://api.github.com/repos/MarkUsProject/Markus/issues/1913"},"comments":{"href":"https://api.github.com/repos/MarkUsProject/Markus/issues/1913/comments"},"review_comments":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913/comments"},"review_comment":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/comments/{number}"},"commits":{"href":"https://api.github.com/repos/MarkUsProject/Markus/pulls/1913/commits"},"statuses":{"href":"https://api.github.com/repos/MarkUsProject/Markus/statuses/e452b59857265f785aaf927368119145b1c559f1"}}}}