{"action":"created","comment":{"url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/comments/100677309","pull_request_review_id":21394563,"id":100677309,"diff_hunk":"@@ -10,31 +10,30 @@\n import re\n import web\n \n-def google_ajax(query): \n-    \"\"\"Search using AjaxSearch, and return its JSON.\"\"\"\n-    if isinstance(query, str): \n-        query = query.encode('utf-8')\n-    uri = 'https://ajax.googleapis.com/ajax/services/search/web'\n-    args = '?v=1.0&safe=off&q=' + web.quote(query)\n-    bytes = web.get(uri + args, headers={'Referer': 'https://github.com/sbp/phenny'})\n-    return web.json(bytes)\n+\n+r_google = re.compile(r'href=\"\\/url\\?q=(http.*?)&')\n \n def google_search(query): \n-    results = google_ajax(query)\n-    try: return results['responseData']['results'][0]['unescapedUrl']\n-    except IndexError: return None\n-    except TypeError: \n-        print(results)\n-        return False\n+    query = web.quote(query)\n+    uri = 'https://google.co.uk/search?q=%s' % query","path":"modules/search.py","position":23,"original_position":23,"commit_id":"71c5f90a5cf0edc9b35d08988a99185104f3b8c6","original_commit_id":"71c5f90a5cf0edc9b35d08988a99185104f3b8c6","user":{"login":"mutantmonkey","id":67266,"avatar_url":"https://avatars.githubusercontent.com/u/67266?v=3","gravatar_id":"","url":"https://api.github.com/users/mutantmonkey","html_url":"https://github.com/mutantmonkey","followers_url":"https://api.github.com/users/mutantmonkey/followers","following_url":"https://api.github.com/users/mutantmonkey/following{/other_user}","gists_url":"https://api.github.com/users/mutantmonkey/gists{/gist_id}","starred_url":"https://api.github.com/users/mutantmonkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mutantmonkey/subscriptions","organizations_url":"https://api.github.com/users/mutantmonkey/orgs","repos_url":"https://api.github.com/users/mutantmonkey/repos","events_url":"https://api.github.com/users/mutantmonkey/events{/privacy}","received_events_url":"https://api.github.com/users/mutantmonkey/received_events","type":"User","site_admin":false},"body":"I'm surprised this works and Google isn't blocking it. Any reason you're using google.co.uk over google.com?","created_at":"2017-02-11T21:28:17Z","updated_at":"2017-02-11T21:34:17Z","html_url":"https://github.com/mutantmonkey/phenny/pull/70#discussion_r100677309","pull_request_url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70","_links":{"self":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/comments/100677309"},"html":{"href":"https://github.com/mutantmonkey/phenny/pull/70#discussion_r100677309"},"pull_request":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70"}}},"pull_request":{"url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70","id":105764002,"html_url":"https://github.com/mutantmonkey/phenny/pull/70","diff_url":"https://github.com/mutantmonkey/phenny/pull/70.diff","patch_url":"https://github.com/mutantmonkey/phenny/pull/70.patch","issue_url":"https://api.github.com/repos/mutantmonkey/phenny/issues/70","number":70,"state":"open","locked":false,"title":"Fix several broken modules, remove mlia, skip vtluugwiki tests until it's back up","user":{"login":"paulwalko","id":2524300,"avatar_url":"https://avatars.githubusercontent.com/u/2524300?v=3","gravatar_id":"","url":"https://api.github.com/users/paulwalko","html_url":"https://github.com/paulwalko","followers_url":"https://api.github.com/users/paulwalko/followers","following_url":"https://api.github.com/users/paulwalko/following{/other_user}","gists_url":"https://api.github.com/users/paulwalko/gists{/gist_id}","starred_url":"https://api.github.com/users/paulwalko/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/paulwalko/subscriptions","organizations_url":"https://api.github.com/users/paulwalko/orgs","repos_url":"https://api.github.com/users/paulwalko/repos","events_url":"https://api.github.com/users/paulwalko/events{/privacy}","received_events_url":"https://api.github.com/users/paulwalko/received_events","type":"User","site_admin":false},"body":"Several search modules needed updating, also added duckduckgo api as preferred method.\r\nFixed bad weather links.\r\nRemoved mlia module since the since seems to be down indefinitely.\r\nSkipped vtluugwiki tests until wiki is back up.","created_at":"2017-02-11T19:11:29Z","updated_at":"2017-02-11T21:34:17Z","closed_at":null,"merged_at":null,"merge_commit_sha":"91d4d4775d8145f79f4ac29bcc60664eb9b1d618","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70/commits","review_comments_url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70/comments","review_comment_url":"https://api.github.com/repos/mutantmonkey/phenny/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mutantmonkey/phenny/issues/70/comments","statuses_url":"https://api.github.com/repos/mutantmonkey/phenny/statuses/71c5f90a5cf0edc9b35d08988a99185104f3b8c6","head":{"label":"vtluug:master","ref":"master","sha":"71c5f90a5cf0edc9b35d08988a99185104f3b8c6","user":{"login":"vtluug","id":5524252,"avatar_url":"https://avatars.githubusercontent.com/u/5524252?v=3","gravatar_id":"","url":"https://api.github.com/users/vtluug","html_url":"https://github.com/vtluug","followers_url":"https://api.github.com/users/vtluug/followers","following_url":"https://api.github.com/users/vtluug/following{/other_user}","gists_url":"https://api.github.com/users/vtluug/gists{/gist_id}","starred_url":"https://api.github.com/users/vtluug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vtluug/subscriptions","organizations_url":"https://api.github.com/users/vtluug/orgs","repos_url":"https://api.github.com/users/vtluug/repos","events_url":"https://api.github.com/users/vtluug/events{/privacy}","received_events_url":"https://api.github.com/users/vtluug/received_events","type":"Organization","site_admin":false},"repo":{"id":81623655,"name":"phenny","full_name":"vtluug/phenny","owner":{"login":"vtluug","id":5524252,"avatar_url":"https://avatars.githubusercontent.com/u/5524252?v=3","gravatar_id":"","url":"https://api.github.com/users/vtluug","html_url":"https://github.com/vtluug","followers_url":"https://api.github.com/users/vtluug/followers","following_url":"https://api.github.com/users/vtluug/following{/other_user}","gists_url":"https://api.github.com/users/vtluug/gists{/gist_id}","starred_url":"https://api.github.com/users/vtluug/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/vtluug/subscriptions","organizations_url":"https://api.github.com/users/vtluug/orgs","repos_url":"https://api.github.com/users/vtluug/repos","events_url":"https://api.github.com/users/vtluug/events{/privacy}","received_events_url":"https://api.github.com/users/vtluug/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/vtluug/phenny","description":"This is phenny, a Python IRC bot.","fork":true,"url":"https://api.github.com/repos/vtluug/phenny","forks_url":"https://api.github.com/repos/vtluug/phenny/forks","keys_url":"https://api.github.com/repos/vtluug/phenny/keys{/key_id}","collaborators_url":"https://api.github.com/repos/vtluug/phenny/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/vtluug/phenny/teams","hooks_url":"https://api.github.com/repos/vtluug/phenny/hooks","issue_events_url":"https://api.github.com/repos/vtluug/phenny/issues/events{/number}","events_url":"https://api.github.com/repos/vtluug/phenny/events","assignees_url":"https://api.github.com/repos/vtluug/phenny/assignees{/user}","branches_url":"https://api.github.com/repos/vtluug/phenny/branches{/branch}","tags_url":"https://api.github.com/repos/vtluug/phenny/tags","blobs_url":"https://api.github.com/repos/vtluug/phenny/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/vtluug/phenny/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/vtluug/phenny/git/refs{/sha}","trees_url":"https://api.github.com/repos/vtluug/phenny/git/trees{/sha}","statuses_url":"https://api.github.com/repos/vtluug/phenny/statuses/{sha}","languages_url":"https://api.github.com/repos/vtluug/phenny/languages","stargazers_url":"https://api.github.com/repos/vtluug/phenny/stargazers","contributors_url":"https://api.github.com/repos/vtluug/phenny/contributors","subscribers_url":"https://api.github.com/repos/vtluug/phenny/subscribers","subscription_url":"https://api.github.com/repos/vtluug/phenny/subscription","commits_url":"https://api.github.com/repos/vtluug/phenny/commits{/sha}","git_commits_url":"https://api.github.com/repos/vtluug/phenny/git/commits{/sha}","comments_url":"https://api.github.com/repos/vtluug/phenny/comments{/number}","issue_comment_url":"https://api.github.com/repos/vtluug/phenny/issues/comments{/number}","contents_url":"https://api.github.com/repos/vtluug/phenny/contents/{+path}","compare_url":"https://api.github.com/repos/vtluug/phenny/compare/{base}...{head}","merges_url":"https://api.github.com/repos/vtluug/phenny/merges","archive_url":"https://api.github.com/repos/vtluug/phenny/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/vtluug/phenny/downloads","issues_url":"https://api.github.com/repos/vtluug/phenny/issues{/number}","pulls_url":"https://api.github.com/repos/vtluug/phenny/pulls{/number}","milestones_url":"https://api.github.com/repos/vtluug/phenny/milestones{/number}","notifications_url":"https://api.github.com/repos/vtluug/phenny/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/vtluug/phenny/labels{/name}","releases_url":"https://api.github.com/repos/vtluug/phenny/releases{/id}","deployments_url":"https://api.github.com/repos/vtluug/phenny/deployments","created_at":"2017-02-11T01:58:16Z","updated_at":"2017-02-11T01:58:18Z","pushed_at":"2017-02-11T19:08:12Z","git_url":"git://github.com/vtluug/phenny.git","ssh_url":"git@github.com:vtluug/phenny.git","clone_url":"https://github.com/vtluug/phenny.git","svn_url":"https://github.com/vtluug/phenny","homepage":"","size":732,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"mutantmonkey:master","ref":"master","sha":"2dc0b0bdd6fe3ccf2803060591d749acebd4278d","user":{"login":"mutantmonkey","id":67266,"avatar_url":"https://avatars.githubusercontent.com/u/67266?v=3","gravatar_id":"","url":"https://api.github.com/users/mutantmonkey","html_url":"https://github.com/mutantmonkey","followers_url":"https://api.github.com/users/mutantmonkey/followers","following_url":"https://api.github.com/users/mutantmonkey/following{/other_user}","gists_url":"https://api.github.com/users/mutantmonkey/gists{/gist_id}","starred_url":"https://api.github.com/users/mutantmonkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mutantmonkey/subscriptions","organizations_url":"https://api.github.com/users/mutantmonkey/orgs","repos_url":"https://api.github.com/users/mutantmonkey/repos","events_url":"https://api.github.com/users/mutantmonkey/events{/privacy}","received_events_url":"https://api.github.com/users/mutantmonkey/received_events","type":"User","site_admin":false},"repo":{"id":1073060,"name":"phenny","full_name":"mutantmonkey/phenny","owner":{"login":"mutantmonkey","id":67266,"avatar_url":"https://avatars.githubusercontent.com/u/67266?v=3","gravatar_id":"","url":"https://api.github.com/users/mutantmonkey","html_url":"https://github.com/mutantmonkey","followers_url":"https://api.github.com/users/mutantmonkey/followers","following_url":"https://api.github.com/users/mutantmonkey/following{/other_user}","gists_url":"https://api.github.com/users/mutantmonkey/gists{/gist_id}","starred_url":"https://api.github.com/users/mutantmonkey/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mutantmonkey/subscriptions","organizations_url":"https://api.github.com/users/mutantmonkey/orgs","repos_url":"https://api.github.com/users/mutantmonkey/repos","events_url":"https://api.github.com/users/mutantmonkey/events{/privacy}","received_events_url":"https://api.github.com/users/mutantmonkey/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mutantmonkey/phenny","description":"This is phenny, a Python IRC bot.","fork":true,"url":"https://api.github.com/repos/mutantmonkey/phenny","forks_url":"https://api.github.com/repos/mutantmonkey/phenny/forks","keys_url":"https://api.github.com/repos/mutantmonkey/phenny/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mutantmonkey/phenny/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mutantmonkey/phenny/teams","hooks_url":"https://api.github.com/repos/mutantmonkey/phenny/hooks","issue_events_url":"https://api.github.com/repos/mutantmonkey/phenny/issues/events{/number}","events_url":"https://api.github.com/repos/mutantmonkey/phenny/events","assignees_url":"https://api.github.com/repos/mutantmonkey/phenny/assignees{/user}","branches_url":"https://api.github.com/repos/mutantmonkey/phenny/branches{/branch}","tags_url":"https://api.github.com/repos/mutantmonkey/phenny/tags","blobs_url":"https://api.github.com/repos/mutantmonkey/phenny/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mutantmonkey/phenny/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mutantmonkey/phenny/git/refs{/sha}","trees_url":"https://api.github.com/repos/mutantmonkey/phenny/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mutantmonkey/phenny/statuses/{sha}","languages_url":"https://api.github.com/repos/mutantmonkey/phenny/languages","stargazers_url":"https://api.github.com/repos/mutantmonkey/phenny/stargazers","contributors_url":"https://api.github.com/repos/mutantmonkey/phenny/contributors","subscribers_url":"https://api.github.com/repos/mutantmonkey/phenny/subscribers","subscription_url":"https://api.github.com/repos/mutantmonkey/phenny/subscription","commits_url":"https://api.github.com/repos/mutantmonkey/phenny/commits{/sha}","git_commits_url":"https://api.github.com/repos/mutantmonkey/phenny/git/commits{/sha}","comments_url":"https://api.github.com/repos/mutantmonkey/phenny/comments{/number}","issue_comment_url":"https://api.github.com/repos/mutantmonkey/phenny/issues/comments{/number}","contents_url":"https://api.github.com/repos/mutantmonkey/phenny/contents/{+path}","compare_url":"https://api.github.com/repos/mutantmonkey/phenny/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mutantmonkey/phenny/merges","archive_url":"https://api.github.com/repos/mutantmonkey/phenny/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mutantmonkey/phenny/downloads","issues_url":"https://api.github.com/repos/mutantmonkey/phenny/issues{/number}","pulls_url":"https://api.github.com/repos/mutantmonkey/phenny/pulls{/number}","milestones_url":"https://api.github.com/repos/mutantmonkey/phenny/milestones{/number}","notifications_url":"https://api.github.com/repos/mutantmonkey/phenny/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mutantmonkey/phenny/labels{/name}","releases_url":"https://api.github.com/repos/mutantmonkey/phenny/releases{/id}","deployments_url":"https://api.github.com/repos/mutantmonkey/phenny/deployments","created_at":"2010-11-11T23:02:01Z","updated_at":"2016-12-31T14:47:16Z","pushed_at":"2017-02-11T21:18:59Z","git_url":"git://github.com/mutantmonkey/phenny.git","ssh_url":"git@github.com:mutantmonkey/phenny.git","clone_url":"https://github.com/mutantmonkey/phenny.git","svn_url":"https://github.com/mutantmonkey/phenny","homepage":"","size":1170,"stargazers_count":16,"watchers_count":16,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":26,"mirror_url":null,"open_issues_count":3,"forks":26,"open_issues":3,"watchers":16,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70"},"html":{"href":"https://github.com/mutantmonkey/phenny/pull/70"},"issue":{"href":"https://api.github.com/repos/mutantmonkey/phenny/issues/70"},"comments":{"href":"https://api.github.com/repos/mutantmonkey/phenny/issues/70/comments"},"review_comments":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70/comments"},"review_comment":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mutantmonkey/phenny/pulls/70/commits"},"statuses":{"href":"https://api.github.com/repos/mutantmonkey/phenny/statuses/71c5f90a5cf0edc9b35d08988a99185104f3b8c6"}}}}
{"actor":{"display_login":"mutantmonkey"}}