{"action":"created","comment":{"url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/comments/64328000","id":64328000,"diff_hunk":"@@ -0,0 +1,188 @@\n+\"\"\"Mergebot is a script which talks to GitHub and submits all ready pull requests.\n+\n+Mergebot talks to a specified GitHub project and watches for @mentions for its account.\n+Acceptable commands are:\n+  @<mergebot-name> merge\n+\"\"\"\n+from subprocess import call\n+import glob\n+import requests\n+import sys\n+import time\n+\n+AUTHORIZED_USERS = [\"davor\"]\n+BOT_NAME = 'beam-testing'\n+GITHUB_ORG = 'apache'\n+REPOSITORY = 'incubator-beam'\n+SECRET_FILE = '../../github_auth/apache-beam.secret'\n+SOURCE_REMOTE = 'github'\n+TARGET_BRANCH = 'master'\n+TARGET_REMOTE = 'apache'\n+\n+GITHUB_API_ROOT = 'https://api.github.com'\n+GITHUB_REPO_FMT_URL = GITHUB_API_ROOT + '/repos/{0}/{1}'\n+GITHUB_REPO_URL = GITHUB_REPO_FMT_URL.format(GITHUB_ORG, REPOSITORY)\n+CMDS = ['merge']\n+ISSUES_URL = GITHUB_REPO_URL + '/issues'\n+COMMENT_FMT_URL = ISSUES_URL + '/{pr_num}/comments'\n+PULLS_URL = GITHUB_REPO_URL + '/pulls'\n+\n+bot_key = ''","path":"merge.py","position":30,"original_position":30,"commit_id":"5d40574c6b334fcfa3d09358ea2a8d2df082450b","original_commit_id":"5d40574c6b334fcfa3d09358ea2a8d2df082450b","user":{"login":"bjchambers","id":35960,"avatar_url":"https://avatars.githubusercontent.com/u/35960?v=3","gravatar_id":"","url":"https://api.github.com/users/bjchambers","html_url":"https://github.com/bjchambers","followers_url":"https://api.github.com/users/bjchambers/followers","following_url":"https://api.github.com/users/bjchambers/following{/other_user}","gists_url":"https://api.github.com/users/bjchambers/gists{/gist_id}","starred_url":"https://api.github.com/users/bjchambers/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/bjchambers/subscriptions","organizations_url":"https://api.github.com/users/bjchambers/orgs","repos_url":"https://api.github.com/users/bjchambers/repos","events_url":"https://api.github.com/users/bjchambers/events{/privacy}","received_events_url":"https://api.github.com/users/bjchambers/received_events","type":"User","site_admin":false},"body":"If you're going to load the `bot_key` in `main`, why define it here?","created_at":"2016-05-24T04:52:01Z","updated_at":"2016-05-24T04:52:01Z","html_url":"https://github.com/jasonkuster/merge-bot/pull/6#discussion_r64328000","pull_request_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6","_links":{"self":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/comments/64328000"},"html":{"href":"https://github.com/jasonkuster/merge-bot/pull/6#discussion_r64328000"},"pull_request":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6"}}},"pull_request":{"url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6","id":71143338,"html_url":"https://github.com/jasonkuster/merge-bot/pull/6","diff_url":"https://github.com/jasonkuster/merge-bot/pull/6.diff","patch_url":"https://github.com/jasonkuster/merge-bot/pull/6.patch","issue_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/6","number":6,"state":"open","locked":false,"title":"Mergebot","user":{"login":"jasonkuster","id":2396054,"avatar_url":"https://avatars.githubusercontent.com/u/2396054?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuster","html_url":"https://github.com/jasonkuster","followers_url":"https://api.github.com/users/jasonkuster/followers","following_url":"https://api.github.com/users/jasonkuster/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuster/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuster/subscriptions","organizations_url":"https://api.github.com/users/jasonkuster/orgs","repos_url":"https://api.github.com/users/jasonkuster/repos","events_url":"https://api.github.com/users/jasonkuster/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuster/received_events","type":"User","site_admin":false},"body":"Commits contain initial project structure (config/, mergebot_poller.py, merge.py) which should just be reviewed for structure, and mergebot.py which should be reviewed for content.","created_at":"2016-05-24T00:57:13Z","updated_at":"2016-05-24T04:52:01Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7861e54593b5f771c0ab89a531c0f587a3715255","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6/commits","review_comments_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6/comments","review_comment_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/comments{/number}","comments_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/6/comments","statuses_url":"https://api.github.com/repos/jasonkuster/merge-bot/statuses/5d40574c6b334fcfa3d09358ea2a8d2df082450b","head":{"label":"jasonkuster:mergebot","ref":"mergebot","sha":"5d40574c6b334fcfa3d09358ea2a8d2df082450b","user":{"login":"jasonkuster","id":2396054,"avatar_url":"https://avatars.githubusercontent.com/u/2396054?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuster","html_url":"https://github.com/jasonkuster","followers_url":"https://api.github.com/users/jasonkuster/followers","following_url":"https://api.github.com/users/jasonkuster/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuster/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuster/subscriptions","organizations_url":"https://api.github.com/users/jasonkuster/orgs","repos_url":"https://api.github.com/users/jasonkuster/repos","events_url":"https://api.github.com/users/jasonkuster/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuster/received_events","type":"User","site_admin":false},"repo":{"id":55528643,"name":"merge-bot","full_name":"jasonkuster/merge-bot","owner":{"login":"jasonkuster","id":2396054,"avatar_url":"https://avatars.githubusercontent.com/u/2396054?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuster","html_url":"https://github.com/jasonkuster","followers_url":"https://api.github.com/users/jasonkuster/followers","following_url":"https://api.github.com/users/jasonkuster/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuster/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuster/subscriptions","organizations_url":"https://api.github.com/users/jasonkuster/orgs","repos_url":"https://api.github.com/users/jasonkuster/repos","events_url":"https://api.github.com/users/jasonkuster/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuster/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jasonkuster/merge-bot","description":"","fork":false,"url":"https://api.github.com/repos/jasonkuster/merge-bot","forks_url":"https://api.github.com/repos/jasonkuster/merge-bot/forks","keys_url":"https://api.github.com/repos/jasonkuster/merge-bot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jasonkuster/merge-bot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jasonkuster/merge-bot/teams","hooks_url":"https://api.github.com/repos/jasonkuster/merge-bot/hooks","issue_events_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/events{/number}","events_url":"https://api.github.com/repos/jasonkuster/merge-bot/events","assignees_url":"https://api.github.com/repos/jasonkuster/merge-bot/assignees{/user}","branches_url":"https://api.github.com/repos/jasonkuster/merge-bot/branches{/branch}","tags_url":"https://api.github.com/repos/jasonkuster/merge-bot/tags","blobs_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/refs{/sha}","trees_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jasonkuster/merge-bot/statuses/{sha}","languages_url":"https://api.github.com/repos/jasonkuster/merge-bot/languages","stargazers_url":"https://api.github.com/repos/jasonkuster/merge-bot/stargazers","contributors_url":"https://api.github.com/repos/jasonkuster/merge-bot/contributors","subscribers_url":"https://api.github.com/repos/jasonkuster/merge-bot/subscribers","subscription_url":"https://api.github.com/repos/jasonkuster/merge-bot/subscription","commits_url":"https://api.github.com/repos/jasonkuster/merge-bot/commits{/sha}","git_commits_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/commits{/sha}","comments_url":"https://api.github.com/repos/jasonkuster/merge-bot/comments{/number}","issue_comment_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/comments{/number}","contents_url":"https://api.github.com/repos/jasonkuster/merge-bot/contents/{+path}","compare_url":"https://api.github.com/repos/jasonkuster/merge-bot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jasonkuster/merge-bot/merges","archive_url":"https://api.github.com/repos/jasonkuster/merge-bot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jasonkuster/merge-bot/downloads","issues_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues{/number}","pulls_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls{/number}","milestones_url":"https://api.github.com/repos/jasonkuster/merge-bot/milestones{/number}","notifications_url":"https://api.github.com/repos/jasonkuster/merge-bot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jasonkuster/merge-bot/labels{/name}","releases_url":"https://api.github.com/repos/jasonkuster/merge-bot/releases{/id}","deployments_url":"https://api.github.com/repos/jasonkuster/merge-bot/deployments","created_at":"2016-04-05T17:37:27Z","updated_at":"2016-05-18T17:18:34Z","pushed_at":"2016-05-24T00:57:13Z","git_url":"git://github.com/jasonkuster/merge-bot.git","ssh_url":"git@github.com:jasonkuster/merge-bot.git","clone_url":"https://github.com/jasonkuster/merge-bot.git","svn_url":"https://github.com/jasonkuster/merge-bot","homepage":null,"size":6,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":4,"forks":0,"open_issues":4,"watchers":0,"default_branch":"master"}},"base":{"label":"jasonkuster:master","ref":"master","sha":"40e31ccc04eb06b02165c9700819f07a7d093754","user":{"login":"jasonkuster","id":2396054,"avatar_url":"https://avatars.githubusercontent.com/u/2396054?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuster","html_url":"https://github.com/jasonkuster","followers_url":"https://api.github.com/users/jasonkuster/followers","following_url":"https://api.github.com/users/jasonkuster/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuster/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuster/subscriptions","organizations_url":"https://api.github.com/users/jasonkuster/orgs","repos_url":"https://api.github.com/users/jasonkuster/repos","events_url":"https://api.github.com/users/jasonkuster/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuster/received_events","type":"User","site_admin":false},"repo":{"id":55528643,"name":"merge-bot","full_name":"jasonkuster/merge-bot","owner":{"login":"jasonkuster","id":2396054,"avatar_url":"https://avatars.githubusercontent.com/u/2396054?v=3","gravatar_id":"","url":"https://api.github.com/users/jasonkuster","html_url":"https://github.com/jasonkuster","followers_url":"https://api.github.com/users/jasonkuster/followers","following_url":"https://api.github.com/users/jasonkuster/following{/other_user}","gists_url":"https://api.github.com/users/jasonkuster/gists{/gist_id}","starred_url":"https://api.github.com/users/jasonkuster/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jasonkuster/subscriptions","organizations_url":"https://api.github.com/users/jasonkuster/orgs","repos_url":"https://api.github.com/users/jasonkuster/repos","events_url":"https://api.github.com/users/jasonkuster/events{/privacy}","received_events_url":"https://api.github.com/users/jasonkuster/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/jasonkuster/merge-bot","description":"","fork":false,"url":"https://api.github.com/repos/jasonkuster/merge-bot","forks_url":"https://api.github.com/repos/jasonkuster/merge-bot/forks","keys_url":"https://api.github.com/repos/jasonkuster/merge-bot/keys{/key_id}","collaborators_url":"https://api.github.com/repos/jasonkuster/merge-bot/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/jasonkuster/merge-bot/teams","hooks_url":"https://api.github.com/repos/jasonkuster/merge-bot/hooks","issue_events_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/events{/number}","events_url":"https://api.github.com/repos/jasonkuster/merge-bot/events","assignees_url":"https://api.github.com/repos/jasonkuster/merge-bot/assignees{/user}","branches_url":"https://api.github.com/repos/jasonkuster/merge-bot/branches{/branch}","tags_url":"https://api.github.com/repos/jasonkuster/merge-bot/tags","blobs_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/refs{/sha}","trees_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/trees{/sha}","statuses_url":"https://api.github.com/repos/jasonkuster/merge-bot/statuses/{sha}","languages_url":"https://api.github.com/repos/jasonkuster/merge-bot/languages","stargazers_url":"https://api.github.com/repos/jasonkuster/merge-bot/stargazers","contributors_url":"https://api.github.com/repos/jasonkuster/merge-bot/contributors","subscribers_url":"https://api.github.com/repos/jasonkuster/merge-bot/subscribers","subscription_url":"https://api.github.com/repos/jasonkuster/merge-bot/subscription","commits_url":"https://api.github.com/repos/jasonkuster/merge-bot/commits{/sha}","git_commits_url":"https://api.github.com/repos/jasonkuster/merge-bot/git/commits{/sha}","comments_url":"https://api.github.com/repos/jasonkuster/merge-bot/comments{/number}","issue_comment_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues/comments{/number}","contents_url":"https://api.github.com/repos/jasonkuster/merge-bot/contents/{+path}","compare_url":"https://api.github.com/repos/jasonkuster/merge-bot/compare/{base}...{head}","merges_url":"https://api.github.com/repos/jasonkuster/merge-bot/merges","archive_url":"https://api.github.com/repos/jasonkuster/merge-bot/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/jasonkuster/merge-bot/downloads","issues_url":"https://api.github.com/repos/jasonkuster/merge-bot/issues{/number}","pulls_url":"https://api.github.com/repos/jasonkuster/merge-bot/pulls{/number}","milestones_url":"https://api.github.com/repos/jasonkuster/merge-bot/milestones{/number}","notifications_url":"https://api.github.com/repos/jasonkuster/merge-bot/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/jasonkuster/merge-bot/labels{/name}","releases_url":"https://api.github.com/repos/jasonkuster/merge-bot/releases{/id}","deployments_url":"https://api.github.com/repos/jasonkuster/merge-bot/deployments","created_at":"2016-04-05T17:37:27Z","updated_at":"2016-05-18T17:18:34Z","pushed_at":"2016-05-24T00:57:13Z","git_url":"git://github.com/jasonkuster/merge-bot.git","ssh_url":"git@github.com:jasonkuster/merge-bot.git","clone_url":"https://github.com/jasonkuster/merge-bot.git","svn_url":"https://github.com/jasonkuster/merge-bot","homepage":null,"size":6,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":4,"forks":0,"open_issues":4,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6"},"html":{"href":"https://github.com/jasonkuster/merge-bot/pull/6"},"issue":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/issues/6"},"comments":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/issues/6/comments"},"review_comments":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6/comments"},"review_comment":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/pulls/6/commits"},"statuses":{"href":"https://api.github.com/repos/jasonkuster/merge-bot/statuses/5d40574c6b334fcfa3d09358ea2a8d2df082450b"}}}}
{"actor":{"display_login":"bjchambers"}}