{"action":"created","comment":{"url":"https://api.github.com/repos/airbnb/airflow/pulls/comments/35059543","id":35059543,"diff_hunk":"@@ -20,11 +20,13 @@ class PrestoHook(BaseHook):\n     >>> ph.get_records(sql)","path":"airflow/hooks/presto_hook.py","position":19,"original_position":19,"commit_id":"4184beaedf93c04d7250de79ff5c77914d2a157a","original_commit_id":"4184beaedf93c04d7250de79ff5c77914d2a157a","user":{"login":"artwr","id":1518713,"avatar_url":"https://avatars.githubusercontent.com/u/1518713?v=3","gravatar_id":"","url":"https://api.github.com/users/artwr","html_url":"https://github.com/artwr","followers_url":"https://api.github.com/users/artwr/followers","following_url":"https://api.github.com/users/artwr/following{/other_user}","gists_url":"https://api.github.com/users/artwr/gists{/gist_id}","starred_url":"https://api.github.com/users/artwr/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/artwr/subscriptions","organizations_url":"https://api.github.com/users/artwr/orgs","repos_url":"https://api.github.com/users/artwr/repos","events_url":"https://api.github.com/users/artwr/events{/privacy}","received_events_url":"https://api.github.com/users/artwr/received_events","type":"User","site_admin":false},"body":"This test somehow fails during unit testing.\r\n`ph = PrestoHook(presto_conn_id='presto_default')` works though.","created_at":"2015-07-21T00:26:33Z","updated_at":"2015-07-21T00:26:33Z","html_url":"https://github.com/airbnb/airflow/pull/146#discussion_r35059543","pull_request_url":"https://api.github.com/repos/airbnb/airflow/pulls/146","_links":{"self":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/comments/35059543"},"html":{"href":"https://github.com/airbnb/airflow/pull/146#discussion_r35059543"},"pull_request":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/146"}}},"pull_request":{"url":"https://api.github.com/repos/airbnb/airflow/pulls/146","id":40189722,"html_url":"https://github.com/airbnb/airflow/pull/146","diff_url":"https://github.com/airbnb/airflow/pull/146.diff","patch_url":"https://github.com/airbnb/airflow/pull/146.patch","issue_url":"https://api.github.com/repos/airbnb/airflow/issues/146","number":146,"state":"open","locked":false,"title":"Generalize presto check operator to work for other backends","user":{"login":"smarden1","id":549155,"avatar_url":"https://avatars.githubusercontent.com/u/549155?v=3","gravatar_id":"","url":"https://api.github.com/users/smarden1","html_url":"https://github.com/smarden1","followers_url":"https://api.github.com/users/smarden1/followers","following_url":"https://api.github.com/users/smarden1/following{/other_user}","gists_url":"https://api.github.com/users/smarden1/gists{/gist_id}","starred_url":"https://api.github.com/users/smarden1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smarden1/subscriptions","organizations_url":"https://api.github.com/users/smarden1/orgs","repos_url":"https://api.github.com/users/smarden1/repos","events_url":"https://api.github.com/users/smarden1/events{/privacy}","received_events_url":"https://api.github.com/users/smarden1/received_events","type":"User","site_admin":false},"body":"This PR attempts to generalize the PrestoCheckOperator family so it can be used with other backends besides Presto.\r\n\r\nThere are two parts to this...\r\n\r\n1. the first part creates a baseSqlHook to ensure that other hooks can easily be used in this CheckOperator\r\n\r\n2. the second part separates out the check implementation from presto.\r\n\r\nI decided to make the operators an abstract class so we can continue the pattern of not instantiating the hook until we are going to execute, rather than creating them in the constructor. Alternatively, I could have passed in a hook and a list of hook parameters but that felt pretty icky.\r\n\r\nI had some problems running the tests on my local machine -- I'm not sure if there are some other instructions that are needed but my hive tests and other external dependencies were failing.","created_at":"2015-07-17T00:14:11Z","updated_at":"2015-07-21T00:26:33Z","closed_at":null,"merged_at":null,"merge_commit_sha":"30e0f0ea23bd09916ea2047c9b3be05c410ee3d7","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/airbnb/airflow/pulls/146/commits","review_comments_url":"https://api.github.com/repos/airbnb/airflow/pulls/146/comments","review_comment_url":"https://api.github.com/repos/airbnb/airflow/pulls/comments{/number}","comments_url":"https://api.github.com/repos/airbnb/airflow/issues/146/comments","statuses_url":"https://api.github.com/repos/airbnb/airflow/statuses/4184beaedf93c04d7250de79ff5c77914d2a157a","head":{"label":"smarden1:generalize-check-operator","ref":"generalize-check-operator","sha":"4184beaedf93c04d7250de79ff5c77914d2a157a","user":{"login":"smarden1","id":549155,"avatar_url":"https://avatars.githubusercontent.com/u/549155?v=3","gravatar_id":"","url":"https://api.github.com/users/smarden1","html_url":"https://github.com/smarden1","followers_url":"https://api.github.com/users/smarden1/followers","following_url":"https://api.github.com/users/smarden1/following{/other_user}","gists_url":"https://api.github.com/users/smarden1/gists{/gist_id}","starred_url":"https://api.github.com/users/smarden1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smarden1/subscriptions","organizations_url":"https://api.github.com/users/smarden1/orgs","repos_url":"https://api.github.com/users/smarden1/repos","events_url":"https://api.github.com/users/smarden1/events{/privacy}","received_events_url":"https://api.github.com/users/smarden1/received_events","type":"User","site_admin":false},"repo":{"id":39166628,"name":"airflow","full_name":"smarden1/airflow","owner":{"login":"smarden1","id":549155,"avatar_url":"https://avatars.githubusercontent.com/u/549155?v=3","gravatar_id":"","url":"https://api.github.com/users/smarden1","html_url":"https://github.com/smarden1","followers_url":"https://api.github.com/users/smarden1/followers","following_url":"https://api.github.com/users/smarden1/following{/other_user}","gists_url":"https://api.github.com/users/smarden1/gists{/gist_id}","starred_url":"https://api.github.com/users/smarden1/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/smarden1/subscriptions","organizations_url":"https://api.github.com/users/smarden1/orgs","repos_url":"https://api.github.com/users/smarden1/repos","events_url":"https://api.github.com/users/smarden1/events{/privacy}","received_events_url":"https://api.github.com/users/smarden1/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/smarden1/airflow","description":"AirFlow is a system to programmatically author, schedule and monitor data pipelines.","fork":true,"url":"https://api.github.com/repos/smarden1/airflow","forks_url":"https://api.github.com/repos/smarden1/airflow/forks","keys_url":"https://api.github.com/repos/smarden1/airflow/keys{/key_id}","collaborators_url":"https://api.github.com/repos/smarden1/airflow/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/smarden1/airflow/teams","hooks_url":"https://api.github.com/repos/smarden1/airflow/hooks","issue_events_url":"https://api.github.com/repos/smarden1/airflow/issues/events{/number}","events_url":"https://api.github.com/repos/smarden1/airflow/events","assignees_url":"https://api.github.com/repos/smarden1/airflow/assignees{/user}","branches_url":"https://api.github.com/repos/smarden1/airflow/branches{/branch}","tags_url":"https://api.github.com/repos/smarden1/airflow/tags","blobs_url":"https://api.github.com/repos/smarden1/airflow/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/smarden1/airflow/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/smarden1/airflow/git/refs{/sha}","trees_url":"https://api.github.com/repos/smarden1/airflow/git/trees{/sha}","statuses_url":"https://api.github.com/repos/smarden1/airflow/statuses/{sha}","languages_url":"https://api.github.com/repos/smarden1/airflow/languages","stargazers_url":"https://api.github.com/repos/smarden1/airflow/stargazers","contributors_url":"https://api.github.com/repos/smarden1/airflow/contributors","subscribers_url":"https://api.github.com/repos/smarden1/airflow/subscribers","subscription_url":"https://api.github.com/repos/smarden1/airflow/subscription","commits_url":"https://api.github.com/repos/smarden1/airflow/commits{/sha}","git_commits_url":"https://api.github.com/repos/smarden1/airflow/git/commits{/sha}","comments_url":"https://api.github.com/repos/smarden1/airflow/comments{/number}","issue_comment_url":"https://api.github.com/repos/smarden1/airflow/issues/comments{/number}","contents_url":"https://api.github.com/repos/smarden1/airflow/contents/{+path}","compare_url":"https://api.github.com/repos/smarden1/airflow/compare/{base}...{head}","merges_url":"https://api.github.com/repos/smarden1/airflow/merges","archive_url":"https://api.github.com/repos/smarden1/airflow/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/smarden1/airflow/downloads","issues_url":"https://api.github.com/repos/smarden1/airflow/issues{/number}","pulls_url":"https://api.github.com/repos/smarden1/airflow/pulls{/number}","milestones_url":"https://api.github.com/repos/smarden1/airflow/milestones{/number}","notifications_url":"https://api.github.com/repos/smarden1/airflow/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/smarden1/airflow/labels{/name}","releases_url":"https://api.github.com/repos/smarden1/airflow/releases{/id}","created_at":"2015-07-15T23:48:08Z","updated_at":"2015-07-15T23:48:09Z","pushed_at":"2015-07-17T22:24:18Z","git_url":"git://github.com/smarden1/airflow.git","ssh_url":"git@github.com:smarden1/airflow.git","clone_url":"https://github.com/smarden1/airflow.git","svn_url":"https://github.com/smarden1/airflow","homepage":null,"size":5402,"stargazers_count":0,"watchers_count":0,"language":"JavaScript","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":"airbnb:master","ref":"master","sha":"8a5bb70fc2808434f50aa864535db225bd85f463","user":{"login":"airbnb","id":698437,"avatar_url":"https://avatars.githubusercontent.com/u/698437?v=3","gravatar_id":"","url":"https://api.github.com/users/airbnb","html_url":"https://github.com/airbnb","followers_url":"https://api.github.com/users/airbnb/followers","following_url":"https://api.github.com/users/airbnb/following{/other_user}","gists_url":"https://api.github.com/users/airbnb/gists{/gist_id}","starred_url":"https://api.github.com/users/airbnb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/airbnb/subscriptions","organizations_url":"https://api.github.com/users/airbnb/orgs","repos_url":"https://api.github.com/users/airbnb/repos","events_url":"https://api.github.com/users/airbnb/events{/privacy}","received_events_url":"https://api.github.com/users/airbnb/received_events","type":"Organization","site_admin":false},"repo":{"id":33884891,"name":"airflow","full_name":"airbnb/airflow","owner":{"login":"airbnb","id":698437,"avatar_url":"https://avatars.githubusercontent.com/u/698437?v=3","gravatar_id":"","url":"https://api.github.com/users/airbnb","html_url":"https://github.com/airbnb","followers_url":"https://api.github.com/users/airbnb/followers","following_url":"https://api.github.com/users/airbnb/following{/other_user}","gists_url":"https://api.github.com/users/airbnb/gists{/gist_id}","starred_url":"https://api.github.com/users/airbnb/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/airbnb/subscriptions","organizations_url":"https://api.github.com/users/airbnb/orgs","repos_url":"https://api.github.com/users/airbnb/repos","events_url":"https://api.github.com/users/airbnb/events{/privacy}","received_events_url":"https://api.github.com/users/airbnb/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/airbnb/airflow","description":"AirFlow is a system to programmatically author, schedule and monitor data pipelines.","fork":false,"url":"https://api.github.com/repos/airbnb/airflow","forks_url":"https://api.github.com/repos/airbnb/airflow/forks","keys_url":"https://api.github.com/repos/airbnb/airflow/keys{/key_id}","collaborators_url":"https://api.github.com/repos/airbnb/airflow/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/airbnb/airflow/teams","hooks_url":"https://api.github.com/repos/airbnb/airflow/hooks","issue_events_url":"https://api.github.com/repos/airbnb/airflow/issues/events{/number}","events_url":"https://api.github.com/repos/airbnb/airflow/events","assignees_url":"https://api.github.com/repos/airbnb/airflow/assignees{/user}","branches_url":"https://api.github.com/repos/airbnb/airflow/branches{/branch}","tags_url":"https://api.github.com/repos/airbnb/airflow/tags","blobs_url":"https://api.github.com/repos/airbnb/airflow/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/airbnb/airflow/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/airbnb/airflow/git/refs{/sha}","trees_url":"https://api.github.com/repos/airbnb/airflow/git/trees{/sha}","statuses_url":"https://api.github.com/repos/airbnb/airflow/statuses/{sha}","languages_url":"https://api.github.com/repos/airbnb/airflow/languages","stargazers_url":"https://api.github.com/repos/airbnb/airflow/stargazers","contributors_url":"https://api.github.com/repos/airbnb/airflow/contributors","subscribers_url":"https://api.github.com/repos/airbnb/airflow/subscribers","subscription_url":"https://api.github.com/repos/airbnb/airflow/subscription","commits_url":"https://api.github.com/repos/airbnb/airflow/commits{/sha}","git_commits_url":"https://api.github.com/repos/airbnb/airflow/git/commits{/sha}","comments_url":"https://api.github.com/repos/airbnb/airflow/comments{/number}","issue_comment_url":"https://api.github.com/repos/airbnb/airflow/issues/comments{/number}","contents_url":"https://api.github.com/repos/airbnb/airflow/contents/{+path}","compare_url":"https://api.github.com/repos/airbnb/airflow/compare/{base}...{head}","merges_url":"https://api.github.com/repos/airbnb/airflow/merges","archive_url":"https://api.github.com/repos/airbnb/airflow/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/airbnb/airflow/downloads","issues_url":"https://api.github.com/repos/airbnb/airflow/issues{/number}","pulls_url":"https://api.github.com/repos/airbnb/airflow/pulls{/number}","milestones_url":"https://api.github.com/repos/airbnb/airflow/milestones{/number}","notifications_url":"https://api.github.com/repos/airbnb/airflow/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/airbnb/airflow/labels{/name}","releases_url":"https://api.github.com/repos/airbnb/airflow/releases{/id}","created_at":"2015-04-13T18:04:58Z","updated_at":"2015-07-20T11:00:45Z","pushed_at":"2015-07-20T23:17:37Z","git_url":"git://github.com/airbnb/airflow.git","ssh_url":"git@github.com:airbnb/airflow.git","clone_url":"https://github.com/airbnb/airflow.git","svn_url":"https://github.com/airbnb/airflow","homepage":null,"size":6719,"stargazers_count":676,"watchers_count":676,"language":"JavaScript","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":87,"mirror_url":null,"open_issues_count":16,"forks":87,"open_issues":16,"watchers":676,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/146"},"html":{"href":"https://github.com/airbnb/airflow/pull/146"},"issue":{"href":"https://api.github.com/repos/airbnb/airflow/issues/146"},"comments":{"href":"https://api.github.com/repos/airbnb/airflow/issues/146/comments"},"review_comments":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/146/comments"},"review_comment":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/airbnb/airflow/pulls/146/commits"},"statuses":{"href":"https://api.github.com/repos/airbnb/airflow/statuses/4184beaedf93c04d7250de79ff5c77914d2a157a"}}}}