{"action":"created","comment":{"url":"https://api.github.com/repos/oppia/oppia/pulls/comments/82061458","pull_request_review_id":2995342,"id":82061458,"diff_hunk":"@@ -460,6 +460,68 @@ def test_next_explorations(self):\n             collection.get_next_exploration_ids(\n                 ['exp_id_0', 'exp_id_1', 'exp_id_2', 'exp_id_3']), [])\n \n+    def test_next_explorations_in_sequence(self):\n+\n+        collection = collection_domain.Collection.create_default_collection(\n+            'collection_id')\n+        exploration_id = 'exp_id_0'\n+        collection.add_node(exploration_id)\n+\n+        # Completing the only exploration of the collection should lead to no\n+        # available explorations thereafter.\n+        self.assertEqual(\n+            collection.get_next_exploration_ids_in_sequence(exploration_id), [])\n+\n+        # If the current exploration has no acquired skills, a blank list\n+        # should be returned.\n+        collection.add_node('exp_id_1')\n+        collection.add_node('exp_id_2')\n+        self.assertEqual(\n+            collection.get_next_exploration_ids_in_sequence(exploration_id),\n+            [])\n+\n+        # If only one exploration in the collection has a prerequisite skill\n+        # that is included in the user's learned skills, only that exploration\n+        # should be returned.\n+        collection_node0 = collection.get_node('exp_id_0')\n+        collection_node1 = collection.get_node('exp_id_1')\n+\n+        collection_node0.update_acquired_skills(['skill1a'])\n+        collection_node1.update_prerequisite_skills(['skill1a'])\n+        self.assertEqual(\n+            collection.get_next_exploration_ids_in_sequence(exploration_id),\n+            ['exp_id_1'])\n+\n+        # Given a chain of explorations in a collections where each\n+        # exploration's acquired skills are the following exploration's\n+        # prerequisite skills, each exploration should return the following\n+        # exploration as a recommendation.  The last exploration should\n+        # return an empty list.\n+        collection.add_node('exp_id_3')\n+\n+        collection_node2 = collection.get_node('exp_id_2')\n+        collection_node3 = collection.get_node('exp_id_3')\n+\n+        collection_node1.update_acquired_skills(['skill2a'])\n+        collection_node2.update_acquired_skills(['skill3a'])\n+\n+        collection_node0.update_prerequisite_skills(['skill1a'])","path":"core/domain/collection_domain_test.py","position":null,"original_position":49,"commit_id":"cb19a7df65c5a28492256aaff76cb5f04fb59d90","original_commit_id":"60bd5eb986274efd02f665df41a7baefb1e18dea","user":{"login":"edallison","id":12070449,"avatar_url":"https://avatars.githubusercontent.com/u/12070449?v=3","gravatar_id":"","url":"https://api.github.com/users/edallison","html_url":"https://github.com/edallison","followers_url":"https://api.github.com/users/edallison/followers","following_url":"https://api.github.com/users/edallison/following{/other_user}","gists_url":"https://api.github.com/users/edallison/gists{/gist_id}","starred_url":"https://api.github.com/users/edallison/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edallison/subscriptions","organizations_url":"https://api.github.com/users/edallison/orgs","repos_url":"https://api.github.com/users/edallison/repos","events_url":"https://api.github.com/users/edallison/events{/privacy}","received_events_url":"https://api.github.com/users/edallison/received_events","type":"User","site_admin":false},"body":"Changed.","created_at":"2016-10-05T20:21:27Z","updated_at":"2016-10-05T20:21:27Z","html_url":"https://github.com/oppia/oppia/pull/2534#discussion_r82061458","pull_request_url":"https://api.github.com/repos/oppia/oppia/pulls/2534","_links":{"self":{"href":"https://api.github.com/repos/oppia/oppia/pulls/comments/82061458"},"html":{"href":"https://github.com/oppia/oppia/pull/2534#discussion_r82061458"},"pull_request":{"href":"https://api.github.com/repos/oppia/oppia/pulls/2534"}}},"pull_request":{"url":"https://api.github.com/repos/oppia/oppia/pulls/2534","id":87543469,"html_url":"https://github.com/oppia/oppia/pull/2534","diff_url":"https://github.com/oppia/oppia/pull/2534.diff","patch_url":"https://github.com/oppia/oppia/pull/2534.patch","issue_url":"https://api.github.com/repos/oppia/oppia/issues/2534","number":2534,"state":"open","locked":false,"title":"Fix #2376: Adds collection recommendation for logged out users","user":{"login":"edallison","id":12070449,"avatar_url":"https://avatars.githubusercontent.com/u/12070449?v=3","gravatar_id":"","url":"https://api.github.com/users/edallison","html_url":"https://github.com/edallison","followers_url":"https://api.github.com/users/edallison/followers","following_url":"https://api.github.com/users/edallison/following{/other_user}","gists_url":"https://api.github.com/users/edallison/gists{/gist_id}","starred_url":"https://api.github.com/users/edallison/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edallison/subscriptions","organizations_url":"https://api.github.com/users/edallison/orgs","repos_url":"https://api.github.com/users/edallison/repos","events_url":"https://api.github.com/users/edallison/events{/privacy}","received_events_url":"https://api.github.com/users/edallison/received_events","type":"User","site_admin":false},"body":"Addressed all comments and added backend tests.","created_at":"2016-09-30T18:32:25Z","updated_at":"2016-10-05T20:21:27Z","closed_at":null,"merged_at":null,"merge_commit_sha":"1236a4c22943f97248304a0bf618120c8288d275","assignee":{"login":"seanlip","id":10575562,"avatar_url":"https://avatars.githubusercontent.com/u/10575562?v=3","gravatar_id":"","url":"https://api.github.com/users/seanlip","html_url":"https://github.com/seanlip","followers_url":"https://api.github.com/users/seanlip/followers","following_url":"https://api.github.com/users/seanlip/following{/other_user}","gists_url":"https://api.github.com/users/seanlip/gists{/gist_id}","starred_url":"https://api.github.com/users/seanlip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seanlip/subscriptions","organizations_url":"https://api.github.com/users/seanlip/orgs","repos_url":"https://api.github.com/users/seanlip/repos","events_url":"https://api.github.com/users/seanlip/events{/privacy}","received_events_url":"https://api.github.com/users/seanlip/received_events","type":"User","site_admin":false},"assignees":[{"login":"seanlip","id":10575562,"avatar_url":"https://avatars.githubusercontent.com/u/10575562?v=3","gravatar_id":"","url":"https://api.github.com/users/seanlip","html_url":"https://github.com/seanlip","followers_url":"https://api.github.com/users/seanlip/followers","following_url":"https://api.github.com/users/seanlip/following{/other_user}","gists_url":"https://api.github.com/users/seanlip/gists{/gist_id}","starred_url":"https://api.github.com/users/seanlip/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seanlip/subscriptions","organizations_url":"https://api.github.com/users/seanlip/orgs","repos_url":"https://api.github.com/users/seanlip/repos","events_url":"https://api.github.com/users/seanlip/events{/privacy}","received_events_url":"https://api.github.com/users/seanlip/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/oppia/oppia/pulls/2534/commits","review_comments_url":"https://api.github.com/repos/oppia/oppia/pulls/2534/comments","review_comment_url":"https://api.github.com/repos/oppia/oppia/pulls/comments{/number}","comments_url":"https://api.github.com/repos/oppia/oppia/issues/2534/comments","statuses_url":"https://api.github.com/repos/oppia/oppia/statuses/cb19a7df65c5a28492256aaff76cb5f04fb59d90","head":{"label":"edallison:exploration-recommendations","ref":"exploration-recommendations","sha":"cb19a7df65c5a28492256aaff76cb5f04fb59d90","user":{"login":"edallison","id":12070449,"avatar_url":"https://avatars.githubusercontent.com/u/12070449?v=3","gravatar_id":"","url":"https://api.github.com/users/edallison","html_url":"https://github.com/edallison","followers_url":"https://api.github.com/users/edallison/followers","following_url":"https://api.github.com/users/edallison/following{/other_user}","gists_url":"https://api.github.com/users/edallison/gists{/gist_id}","starred_url":"https://api.github.com/users/edallison/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edallison/subscriptions","organizations_url":"https://api.github.com/users/edallison/orgs","repos_url":"https://api.github.com/users/edallison/repos","events_url":"https://api.github.com/users/edallison/events{/privacy}","received_events_url":"https://api.github.com/users/edallison/received_events","type":"User","site_admin":false},"repo":{"id":41883913,"name":"oppia","full_name":"edallison/oppia","owner":{"login":"edallison","id":12070449,"avatar_url":"https://avatars.githubusercontent.com/u/12070449?v=3","gravatar_id":"","url":"https://api.github.com/users/edallison","html_url":"https://github.com/edallison","followers_url":"https://api.github.com/users/edallison/followers","following_url":"https://api.github.com/users/edallison/following{/other_user}","gists_url":"https://api.github.com/users/edallison/gists{/gist_id}","starred_url":"https://api.github.com/users/edallison/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/edallison/subscriptions","organizations_url":"https://api.github.com/users/edallison/orgs","repos_url":"https://api.github.com/users/edallison/repos","events_url":"https://api.github.com/users/edallison/events{/privacy}","received_events_url":"https://api.github.com/users/edallison/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/edallison/oppia","description":"Tool for creating interactive tutors.","fork":true,"url":"https://api.github.com/repos/edallison/oppia","forks_url":"https://api.github.com/repos/edallison/oppia/forks","keys_url":"https://api.github.com/repos/edallison/oppia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/edallison/oppia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/edallison/oppia/teams","hooks_url":"https://api.github.com/repos/edallison/oppia/hooks","issue_events_url":"https://api.github.com/repos/edallison/oppia/issues/events{/number}","events_url":"https://api.github.com/repos/edallison/oppia/events","assignees_url":"https://api.github.com/repos/edallison/oppia/assignees{/user}","branches_url":"https://api.github.com/repos/edallison/oppia/branches{/branch}","tags_url":"https://api.github.com/repos/edallison/oppia/tags","blobs_url":"https://api.github.com/repos/edallison/oppia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/edallison/oppia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/edallison/oppia/git/refs{/sha}","trees_url":"https://api.github.com/repos/edallison/oppia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/edallison/oppia/statuses/{sha}","languages_url":"https://api.github.com/repos/edallison/oppia/languages","stargazers_url":"https://api.github.com/repos/edallison/oppia/stargazers","contributors_url":"https://api.github.com/repos/edallison/oppia/contributors","subscribers_url":"https://api.github.com/repos/edallison/oppia/subscribers","subscription_url":"https://api.github.com/repos/edallison/oppia/subscription","commits_url":"https://api.github.com/repos/edallison/oppia/commits{/sha}","git_commits_url":"https://api.github.com/repos/edallison/oppia/git/commits{/sha}","comments_url":"https://api.github.com/repos/edallison/oppia/comments{/number}","issue_comment_url":"https://api.github.com/repos/edallison/oppia/issues/comments{/number}","contents_url":"https://api.github.com/repos/edallison/oppia/contents/{+path}","compare_url":"https://api.github.com/repos/edallison/oppia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/edallison/oppia/merges","archive_url":"https://api.github.com/repos/edallison/oppia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/edallison/oppia/downloads","issues_url":"https://api.github.com/repos/edallison/oppia/issues{/number}","pulls_url":"https://api.github.com/repos/edallison/oppia/pulls{/number}","milestones_url":"https://api.github.com/repos/edallison/oppia/milestones{/number}","notifications_url":"https://api.github.com/repos/edallison/oppia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/edallison/oppia/labels{/name}","releases_url":"https://api.github.com/repos/edallison/oppia/releases{/id}","deployments_url":"https://api.github.com/repos/edallison/oppia/deployments","created_at":"2015-09-03T21:09:23Z","updated_at":"2016-05-05T23:35:50Z","pushed_at":"2016-10-05T20:19:09Z","git_url":"git://github.com/edallison/oppia.git","ssh_url":"git@github.com:edallison/oppia.git","clone_url":"https://github.com/edallison/oppia.git","svn_url":"https://github.com/edallison/oppia","homepage":"https://www.oppia.org","size":47083,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":false,"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":"develop"}},"base":{"label":"oppia:develop","ref":"develop","sha":"f3ab498c705c217598ecd53429033349cb82d633","user":{"login":"oppia","id":11620230,"avatar_url":"https://avatars.githubusercontent.com/u/11620230?v=3","gravatar_id":"","url":"https://api.github.com/users/oppia","html_url":"https://github.com/oppia","followers_url":"https://api.github.com/users/oppia/followers","following_url":"https://api.github.com/users/oppia/following{/other_user}","gists_url":"https://api.github.com/users/oppia/gists{/gist_id}","starred_url":"https://api.github.com/users/oppia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oppia/subscriptions","organizations_url":"https://api.github.com/users/oppia/orgs","repos_url":"https://api.github.com/users/oppia/repos","events_url":"https://api.github.com/users/oppia/events{/privacy}","received_events_url":"https://api.github.com/users/oppia/received_events","type":"Organization","site_admin":false},"repo":{"id":40687563,"name":"oppia","full_name":"oppia/oppia","owner":{"login":"oppia","id":11620230,"avatar_url":"https://avatars.githubusercontent.com/u/11620230?v=3","gravatar_id":"","url":"https://api.github.com/users/oppia","html_url":"https://github.com/oppia","followers_url":"https://api.github.com/users/oppia/followers","following_url":"https://api.github.com/users/oppia/following{/other_user}","gists_url":"https://api.github.com/users/oppia/gists{/gist_id}","starred_url":"https://api.github.com/users/oppia/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/oppia/subscriptions","organizations_url":"https://api.github.com/users/oppia/orgs","repos_url":"https://api.github.com/users/oppia/repos","events_url":"https://api.github.com/users/oppia/events{/privacy}","received_events_url":"https://api.github.com/users/oppia/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/oppia/oppia","description":"Tool for collaboratively building interactive lessons.","fork":false,"url":"https://api.github.com/repos/oppia/oppia","forks_url":"https://api.github.com/repos/oppia/oppia/forks","keys_url":"https://api.github.com/repos/oppia/oppia/keys{/key_id}","collaborators_url":"https://api.github.com/repos/oppia/oppia/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/oppia/oppia/teams","hooks_url":"https://api.github.com/repos/oppia/oppia/hooks","issue_events_url":"https://api.github.com/repos/oppia/oppia/issues/events{/number}","events_url":"https://api.github.com/repos/oppia/oppia/events","assignees_url":"https://api.github.com/repos/oppia/oppia/assignees{/user}","branches_url":"https://api.github.com/repos/oppia/oppia/branches{/branch}","tags_url":"https://api.github.com/repos/oppia/oppia/tags","blobs_url":"https://api.github.com/repos/oppia/oppia/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/oppia/oppia/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/oppia/oppia/git/refs{/sha}","trees_url":"https://api.github.com/repos/oppia/oppia/git/trees{/sha}","statuses_url":"https://api.github.com/repos/oppia/oppia/statuses/{sha}","languages_url":"https://api.github.com/repos/oppia/oppia/languages","stargazers_url":"https://api.github.com/repos/oppia/oppia/stargazers","contributors_url":"https://api.github.com/repos/oppia/oppia/contributors","subscribers_url":"https://api.github.com/repos/oppia/oppia/subscribers","subscription_url":"https://api.github.com/repos/oppia/oppia/subscription","commits_url":"https://api.github.com/repos/oppia/oppia/commits{/sha}","git_commits_url":"https://api.github.com/repos/oppia/oppia/git/commits{/sha}","comments_url":"https://api.github.com/repos/oppia/oppia/comments{/number}","issue_comment_url":"https://api.github.com/repos/oppia/oppia/issues/comments{/number}","contents_url":"https://api.github.com/repos/oppia/oppia/contents/{+path}","compare_url":"https://api.github.com/repos/oppia/oppia/compare/{base}...{head}","merges_url":"https://api.github.com/repos/oppia/oppia/merges","archive_url":"https://api.github.com/repos/oppia/oppia/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/oppia/oppia/downloads","issues_url":"https://api.github.com/repos/oppia/oppia/issues{/number}","pulls_url":"https://api.github.com/repos/oppia/oppia/pulls{/number}","milestones_url":"https://api.github.com/repos/oppia/oppia/milestones{/number}","notifications_url":"https://api.github.com/repos/oppia/oppia/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/oppia/oppia/labels{/name}","releases_url":"https://api.github.com/repos/oppia/oppia/releases{/id}","deployments_url":"https://api.github.com/repos/oppia/oppia/deployments","created_at":"2015-08-14T00:16:14Z","updated_at":"2016-10-05T15:29:48Z","pushed_at":"2016-10-05T20:19:10Z","git_url":"git://github.com/oppia/oppia.git","ssh_url":"git@github.com:oppia/oppia.git","clone_url":"https://github.com/oppia/oppia.git","svn_url":"https://github.com/oppia/oppia","homepage":"https://www.oppia.org","size":90040,"stargazers_count":169,"watchers_count":169,"language":"Python","has_issues":true,"has_downloads":false,"has_wiki":true,"has_pages":false,"forks_count":253,"mirror_url":null,"open_issues_count":346,"forks":253,"open_issues":346,"watchers":169,"default_branch":"develop"}},"_links":{"self":{"href":"https://api.github.com/repos/oppia/oppia/pulls/2534"},"html":{"href":"https://github.com/oppia/oppia/pull/2534"},"issue":{"href":"https://api.github.com/repos/oppia/oppia/issues/2534"},"comments":{"href":"https://api.github.com/repos/oppia/oppia/issues/2534/comments"},"review_comments":{"href":"https://api.github.com/repos/oppia/oppia/pulls/2534/comments"},"review_comment":{"href":"https://api.github.com/repos/oppia/oppia/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/oppia/oppia/pulls/2534/commits"},"statuses":{"href":"https://api.github.com/repos/oppia/oppia/statuses/cb19a7df65c5a28492256aaff76cb5f04fb59d90"}}}}
{"actor":{"display_login":"edallison"}}