{"action":"created","comment":{"url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/comments/166888772","pull_request_review_id":95020993,"id":166888772,"diff_hunk":"@@ -1,23 +1,47 @@\n import csv\n+import os\n+import pandas as pd\n+import xlrd\n from db_connector import User\n \n class FileLoader(object):\n-    def __init__(self, val):\n-        self.file = val\n+    def __init__(self, path_to_file):\n+        self.filename, self.file_extension = os.path.splitext(path_to_file)\n+\n+    def xlsx_data_import_db(self, file_buffer, db_conn):\n+        df = pd.read_excel(file_buffer, sheet_name='Sample-spreadsheet-file')\n+\n+        for i in df.index:\n+            self.import_each_record([df['Name'][i], df['Age'][i], df['Address'][i]], db_conn)","path":"file_importer.py","position":17,"original_position":17,"commit_id":"84c6bbe0f7edc1c26e03be825cb485e17b50a1ec","original_commit_id":"84c6bbe0f7edc1c26e03be825cb485e17b50a1ec","user":{"login":"houndci-bot","id":6697940,"avatar_url":"https://avatars0.githubusercontent.com/u/6697940?v=4","gravatar_id":"","url":"https://api.github.com/users/houndci-bot","html_url":"https://github.com/houndci-bot","followers_url":"https://api.github.com/users/houndci-bot/followers","following_url":"https://api.github.com/users/houndci-bot/following{/other_user}","gists_url":"https://api.github.com/users/houndci-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/houndci-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/houndci-bot/subscriptions","organizations_url":"https://api.github.com/users/houndci-bot/orgs","repos_url":"https://api.github.com/users/houndci-bot/repos","events_url":"https://api.github.com/users/houndci-bot/events{/privacy}","received_events_url":"https://api.github.com/users/houndci-bot/received_events","type":"User","site_admin":false},"body":"line too long (93 > 79 characters)","created_at":"2018-02-08T10:25:09Z","updated_at":"2018-02-08T10:25:09Z","html_url":"https://github.com/lunaimaginea/import_data_cli/pull/5#discussion_r166888772","pull_request_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5","author_association":"NONE","_links":{"self":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/comments/166888772"},"html":{"href":"https://github.com/lunaimaginea/import_data_cli/pull/5#discussion_r166888772"},"pull_request":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5"}}},"pull_request":{"url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5","id":167930888,"html_url":"https://github.com/lunaimaginea/import_data_cli/pull/5","diff_url":"https://github.com/lunaimaginea/import_data_cli/pull/5.diff","patch_url":"https://github.com/lunaimaginea/import_data_cli/pull/5.patch","issue_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/5","number":5,"state":"open","locked":false,"title":"Feature xls support","user":{"login":"lunaimaginea","id":32506821,"avatar_url":"https://avatars2.githubusercontent.com/u/32506821?v=4","gravatar_id":"","url":"https://api.github.com/users/lunaimaginea","html_url":"https://github.com/lunaimaginea","followers_url":"https://api.github.com/users/lunaimaginea/followers","following_url":"https://api.github.com/users/lunaimaginea/following{/other_user}","gists_url":"https://api.github.com/users/lunaimaginea/gists{/gist_id}","starred_url":"https://api.github.com/users/lunaimaginea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lunaimaginea/subscriptions","organizations_url":"https://api.github.com/users/lunaimaginea/orgs","repos_url":"https://api.github.com/users/lunaimaginea/repos","events_url":"https://api.github.com/users/lunaimaginea/events{/privacy}","received_events_url":"https://api.github.com/users/lunaimaginea/received_events","type":"User","site_admin":false},"body":"","created_at":"2018-02-08T10:25:01Z","updated_at":"2018-02-08T10:25:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"7cfb5c2b11c3d8042810ef87f8af0b7e737a7761","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"milestone":null,"commits_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5/commits","review_comments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5/comments","review_comment_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/comments{/number}","comments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/5/comments","statuses_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/statuses/84c6bbe0f7edc1c26e03be825cb485e17b50a1ec","head":{"label":"lunaimaginea:feature_xls_support","ref":"feature_xls_support","sha":"84c6bbe0f7edc1c26e03be825cb485e17b50a1ec","user":{"login":"lunaimaginea","id":32506821,"avatar_url":"https://avatars2.githubusercontent.com/u/32506821?v=4","gravatar_id":"","url":"https://api.github.com/users/lunaimaginea","html_url":"https://github.com/lunaimaginea","followers_url":"https://api.github.com/users/lunaimaginea/followers","following_url":"https://api.github.com/users/lunaimaginea/following{/other_user}","gists_url":"https://api.github.com/users/lunaimaginea/gists{/gist_id}","starred_url":"https://api.github.com/users/lunaimaginea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lunaimaginea/subscriptions","organizations_url":"https://api.github.com/users/lunaimaginea/orgs","repos_url":"https://api.github.com/users/lunaimaginea/repos","events_url":"https://api.github.com/users/lunaimaginea/events{/privacy}","received_events_url":"https://api.github.com/users/lunaimaginea/received_events","type":"User","site_admin":false},"repo":{"id":119815275,"name":"import_data_cli","full_name":"lunaimaginea/import_data_cli","owner":{"login":"lunaimaginea","id":32506821,"avatar_url":"https://avatars2.githubusercontent.com/u/32506821?v=4","gravatar_id":"","url":"https://api.github.com/users/lunaimaginea","html_url":"https://github.com/lunaimaginea","followers_url":"https://api.github.com/users/lunaimaginea/followers","following_url":"https://api.github.com/users/lunaimaginea/following{/other_user}","gists_url":"https://api.github.com/users/lunaimaginea/gists{/gist_id}","starred_url":"https://api.github.com/users/lunaimaginea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lunaimaginea/subscriptions","organizations_url":"https://api.github.com/users/lunaimaginea/orgs","repos_url":"https://api.github.com/users/lunaimaginea/repos","events_url":"https://api.github.com/users/lunaimaginea/events{/privacy}","received_events_url":"https://api.github.com/users/lunaimaginea/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lunaimaginea/import_data_cli","description":null,"fork":false,"url":"https://api.github.com/repos/lunaimaginea/import_data_cli","forks_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/forks","keys_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/teams","hooks_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/hooks","issue_events_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/events{/number}","events_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/events","assignees_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/assignees{/user}","branches_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/branches{/branch}","tags_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/tags","blobs_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/statuses/{sha}","languages_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/languages","stargazers_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/stargazers","contributors_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/contributors","subscribers_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/subscribers","subscription_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/subscription","commits_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/contents/{+path}","compare_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/merges","archive_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/downloads","issues_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues{/number}","pulls_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls{/number}","milestones_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/milestones{/number}","notifications_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/labels{/name}","releases_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/releases{/id}","deployments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/deployments","created_at":"2018-02-01T09:43:19Z","updated_at":"2018-02-07T13:24:05Z","pushed_at":"2018-02-08T10:25:01Z","git_url":"git://github.com/lunaimaginea/import_data_cli.git","ssh_url":"git@github.com:lunaimaginea/import_data_cli.git","clone_url":"https://github.com/lunaimaginea/import_data_cli.git","svn_url":"https://github.com/lunaimaginea/import_data_cli","homepage":null,"size":5,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"base":{"label":"lunaimaginea:master","ref":"master","sha":"942fda402eef44dffdb6739b4fecdd6c3a2b36f5","user":{"login":"lunaimaginea","id":32506821,"avatar_url":"https://avatars2.githubusercontent.com/u/32506821?v=4","gravatar_id":"","url":"https://api.github.com/users/lunaimaginea","html_url":"https://github.com/lunaimaginea","followers_url":"https://api.github.com/users/lunaimaginea/followers","following_url":"https://api.github.com/users/lunaimaginea/following{/other_user}","gists_url":"https://api.github.com/users/lunaimaginea/gists{/gist_id}","starred_url":"https://api.github.com/users/lunaimaginea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lunaimaginea/subscriptions","organizations_url":"https://api.github.com/users/lunaimaginea/orgs","repos_url":"https://api.github.com/users/lunaimaginea/repos","events_url":"https://api.github.com/users/lunaimaginea/events{/privacy}","received_events_url":"https://api.github.com/users/lunaimaginea/received_events","type":"User","site_admin":false},"repo":{"id":119815275,"name":"import_data_cli","full_name":"lunaimaginea/import_data_cli","owner":{"login":"lunaimaginea","id":32506821,"avatar_url":"https://avatars2.githubusercontent.com/u/32506821?v=4","gravatar_id":"","url":"https://api.github.com/users/lunaimaginea","html_url":"https://github.com/lunaimaginea","followers_url":"https://api.github.com/users/lunaimaginea/followers","following_url":"https://api.github.com/users/lunaimaginea/following{/other_user}","gists_url":"https://api.github.com/users/lunaimaginea/gists{/gist_id}","starred_url":"https://api.github.com/users/lunaimaginea/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lunaimaginea/subscriptions","organizations_url":"https://api.github.com/users/lunaimaginea/orgs","repos_url":"https://api.github.com/users/lunaimaginea/repos","events_url":"https://api.github.com/users/lunaimaginea/events{/privacy}","received_events_url":"https://api.github.com/users/lunaimaginea/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/lunaimaginea/import_data_cli","description":null,"fork":false,"url":"https://api.github.com/repos/lunaimaginea/import_data_cli","forks_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/forks","keys_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/keys{/key_id}","collaborators_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/teams","hooks_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/hooks","issue_events_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/events{/number}","events_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/events","assignees_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/assignees{/user}","branches_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/branches{/branch}","tags_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/tags","blobs_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/refs{/sha}","trees_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/trees{/sha}","statuses_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/statuses/{sha}","languages_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/languages","stargazers_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/stargazers","contributors_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/contributors","subscribers_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/subscribers","subscription_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/subscription","commits_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/commits{/sha}","git_commits_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/git/commits{/sha}","comments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/comments{/number}","issue_comment_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/comments{/number}","contents_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/contents/{+path}","compare_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/compare/{base}...{head}","merges_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/merges","archive_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/downloads","issues_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues{/number}","pulls_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls{/number}","milestones_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/milestones{/number}","notifications_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/labels{/name}","releases_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/releases{/id}","deployments_url":"https://api.github.com/repos/lunaimaginea/import_data_cli/deployments","created_at":"2018-02-01T09:43:19Z","updated_at":"2018-02-07T13:24:05Z","pushed_at":"2018-02-08T10:25:01Z","git_url":"git://github.com/lunaimaginea/import_data_cli.git","ssh_url":"git@github.com:lunaimaginea/import_data_cli.git","clone_url":"https://github.com/lunaimaginea/import_data_cli.git","svn_url":"https://github.com/lunaimaginea/import_data_cli","homepage":null,"size":5,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":2,"license":null,"forks":0,"open_issues":2,"watchers":0,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5"},"html":{"href":"https://github.com/lunaimaginea/import_data_cli/pull/5"},"issue":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/5"},"comments":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/issues/5/comments"},"review_comments":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5/comments"},"review_comment":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/pulls/5/commits"},"statuses":{"href":"https://api.github.com/repos/lunaimaginea/import_data_cli/statuses/84c6bbe0f7edc1c26e03be825cb485e17b50a1ec"}},"author_association":"OWNER"}}
{"actor":{"display_login":"houndci-bot"}}