{"action":"created","comment":{"url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/comments/78427135","id":78427135,"diff_hunk":"@@ -0,0 +1,54 @@\n+#!/usr/bin/env python3\n+\n+import importlib\n+import sys\n+\n+from sqlalchemy import create_engine\n+from sqlalchemy.orm import sessionmaker\n+import yaml\n+\n+\n+def import_class(what):\n+    \"\"\" Imports a class by given full name\n+    Args:\n+        what (str): a string with full classname to import\n+    Return:\n+        (type): a class which has been imported\n+    \"\"\"\n+    modulename, classname = what.rsplit('.', 1)\n+    module = importlib.import_module(modulename)\n+    return getattr(module, classname)\n+\n+\n+def load_fixtures(filepath):\n+    \"\"\" Loads fixtures from given file\n+    Args:\n+        filepath (str): path to file from which fixtures should be imported\n+    Returns:\n+        (list): list of instantiated objects\n+    \"\"\"\n+    models = []\n+    with open(filepath, 'r') as data_file:\n+        data = yaml.safe_load(data_file)\n+        for cls, descriptions in data.items():\n+            model_cls = import_class(cls)\n+            for description in descriptions:\n+                models.append(model_cls(**description))\n+    return models\n+\n+\n+def main():\n+    db_url, *filepathes = sys.argv[1:]\n+\n+    engine = create_engine(db_url)\n+    Session = sessionmaker(bind=engine)","path":"fixtures/loader.py","position":44,"original_position":44,"commit_id":"3cda115b189443873d641c7cb79a8432ae99e92d","original_commit_id":"3cda115b189443873d641c7cb79a8432ae99e92d","user":{"login":"codacy-bot","id":19940114,"avatar_url":"https://avatars.githubusercontent.com/u/19940114?v=3","gravatar_id":"","url":"https://api.github.com/users/codacy-bot","html_url":"https://github.com/codacy-bot","followers_url":"https://api.github.com/users/codacy-bot/followers","following_url":"https://api.github.com/users/codacy-bot/following{/other_user}","gists_url":"https://api.github.com/users/codacy-bot/gists{/gist_id}","starred_url":"https://api.github.com/users/codacy-bot/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/codacy-bot/subscriptions","organizations_url":"https://api.github.com/users/codacy-bot/orgs","repos_url":"https://api.github.com/users/codacy-bot/repos","events_url":"https://api.github.com/users/codacy-bot/events{/privacy}","received_events_url":"https://api.github.com/users/codacy-bot/received_events","type":"User","site_admin":false},"body":"![Codacy](https://www.codacy.com/assets/images/favicon.png) Issue found: [Invalid variable name \"Session\"](https://www.codacy.com/app/wk-org/gdg-org-ua/file/3885927578/issues/source?bid=3283927&fileBranchId=3615386#l44)","created_at":"2016-09-12T18:25:09Z","updated_at":"2016-09-12T18:25:09Z","html_url":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113#discussion_r78427135","pull_request_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113","_links":{"self":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/comments/78427135"},"html":{"href":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113#discussion_r78427135"},"pull_request":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113"}}},"pull_request":{"url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113","id":82120773,"html_url":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113","diff_url":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113.diff","patch_url":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113.patch","issue_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/113","number":113,"state":"open","locked":false,"title":"[#57] Automate development workflow with vagga","user":{"login":"anxolerd","id":6533582,"avatar_url":"https://avatars.githubusercontent.com/u/6533582?v=3","gravatar_id":"","url":"https://api.github.com/users/anxolerd","html_url":"https://github.com/anxolerd","followers_url":"https://api.github.com/users/anxolerd/followers","following_url":"https://api.github.com/users/anxolerd/following{/other_user}","gists_url":"https://api.github.com/users/anxolerd/gists{/gist_id}","starred_url":"https://api.github.com/users/anxolerd/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/anxolerd/subscriptions","organizations_url":"https://api.github.com/users/anxolerd/orgs","repos_url":"https://api.github.com/users/anxolerd/repos","events_url":"https://api.github.com/users/anxolerd/events{/privacy}","received_events_url":"https://api.github.com/users/anxolerd/received_events","type":"User","site_admin":false},"body":"Here is a basic `vagga.yaml`, which starts an application alongside mysql database. Once it is complete, it should resolve #57.\r\nA `vagrant-vagga` is used to run this on OSX.\r\nA @phiNumber's PR (#97) was taken as a base.\r\n\r\nHowever I have a problem with configuring\r\n* [x] fixtures\r\n* [ ] blueberrypy config\r\n\r\nPlease can anybody look into it?\r\n\r\n/cc @webknjaz @cleac ","created_at":"2016-08-21T23:29:07Z","updated_at":"2016-09-12T18:25:09Z","closed_at":null,"merged_at":null,"merge_commit_sha":"9f6c5b3be72385f513e10af71c725c20b7ee45ba","assignee":{"login":"webknjaz","id":578543,"avatar_url":"https://avatars.githubusercontent.com/u/578543?v=3","gravatar_id":"","url":"https://api.github.com/users/webknjaz","html_url":"https://github.com/webknjaz","followers_url":"https://api.github.com/users/webknjaz/followers","following_url":"https://api.github.com/users/webknjaz/following{/other_user}","gists_url":"https://api.github.com/users/webknjaz/gists{/gist_id}","starred_url":"https://api.github.com/users/webknjaz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webknjaz/subscriptions","organizations_url":"https://api.github.com/users/webknjaz/orgs","repos_url":"https://api.github.com/users/webknjaz/repos","events_url":"https://api.github.com/users/webknjaz/events{/privacy}","received_events_url":"https://api.github.com/users/webknjaz/received_events","type":"User","site_admin":false},"assignees":[{"login":"webknjaz","id":578543,"avatar_url":"https://avatars.githubusercontent.com/u/578543?v=3","gravatar_id":"","url":"https://api.github.com/users/webknjaz","html_url":"https://github.com/webknjaz","followers_url":"https://api.github.com/users/webknjaz/followers","following_url":"https://api.github.com/users/webknjaz/following{/other_user}","gists_url":"https://api.github.com/users/webknjaz/gists{/gist_id}","starred_url":"https://api.github.com/users/webknjaz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/webknjaz/subscriptions","organizations_url":"https://api.github.com/users/webknjaz/orgs","repos_url":"https://api.github.com/users/webknjaz/repos","events_url":"https://api.github.com/users/webknjaz/events{/privacy}","received_events_url":"https://api.github.com/users/webknjaz/received_events","type":"User","site_admin":false},{"login":"cleac","id":8603674,"avatar_url":"https://avatars.githubusercontent.com/u/8603674?v=3","gravatar_id":"","url":"https://api.github.com/users/cleac","html_url":"https://github.com/cleac","followers_url":"https://api.github.com/users/cleac/followers","following_url":"https://api.github.com/users/cleac/following{/other_user}","gists_url":"https://api.github.com/users/cleac/gists{/gist_id}","starred_url":"https://api.github.com/users/cleac/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/cleac/subscriptions","organizations_url":"https://api.github.com/users/cleac/orgs","repos_url":"https://api.github.com/users/cleac/repos","events_url":"https://api.github.com/users/cleac/events{/privacy}","received_events_url":"https://api.github.com/users/cleac/received_events","type":"User","site_admin":false}],"milestone":null,"commits_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113/commits","review_comments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113/comments","review_comment_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/comments{/number}","comments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/113/comments","statuses_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/statuses/3cda115b189443873d641c7cb79a8432ae99e92d","head":{"label":"GDG-Ukraine:57-vagga-config","ref":"57-vagga-config","sha":"3cda115b189443873d641c7cb79a8432ae99e92d","user":{"login":"GDG-Ukraine","id":2266906,"avatar_url":"https://avatars.githubusercontent.com/u/2266906?v=3","gravatar_id":"","url":"https://api.github.com/users/GDG-Ukraine","html_url":"https://github.com/GDG-Ukraine","followers_url":"https://api.github.com/users/GDG-Ukraine/followers","following_url":"https://api.github.com/users/GDG-Ukraine/following{/other_user}","gists_url":"https://api.github.com/users/GDG-Ukraine/gists{/gist_id}","starred_url":"https://api.github.com/users/GDG-Ukraine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GDG-Ukraine/subscriptions","organizations_url":"https://api.github.com/users/GDG-Ukraine/orgs","repos_url":"https://api.github.com/users/GDG-Ukraine/repos","events_url":"https://api.github.com/users/GDG-Ukraine/events{/privacy}","received_events_url":"https://api.github.com/users/GDG-Ukraine/received_events","type":"Organization","site_admin":false},"repo":{"id":7036517,"name":"gdg.org.ua","full_name":"GDG-Ukraine/gdg.org.ua","owner":{"login":"GDG-Ukraine","id":2266906,"avatar_url":"https://avatars.githubusercontent.com/u/2266906?v=3","gravatar_id":"","url":"https://api.github.com/users/GDG-Ukraine","html_url":"https://github.com/GDG-Ukraine","followers_url":"https://api.github.com/users/GDG-Ukraine/followers","following_url":"https://api.github.com/users/GDG-Ukraine/following{/other_user}","gists_url":"https://api.github.com/users/GDG-Ukraine/gists{/gist_id}","starred_url":"https://api.github.com/users/GDG-Ukraine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GDG-Ukraine/subscriptions","organizations_url":"https://api.github.com/users/GDG-Ukraine/orgs","repos_url":"https://api.github.com/users/GDG-Ukraine/repos","events_url":"https://api.github.com/users/GDG-Ukraine/events{/privacy}","received_events_url":"https://api.github.com/users/GDG-Ukraine/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GDG-Ukraine/gdg.org.ua","description":"GDG Ukraine website, event registration forms.","fork":false,"url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua","forks_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/forks","keys_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/teams","hooks_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/hooks","issue_events_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/events{/number}","events_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/events","assignees_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/assignees{/user}","branches_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/branches{/branch}","tags_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/tags","blobs_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/refs{/sha}","trees_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/statuses/{sha}","languages_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/languages","stargazers_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/stargazers","contributors_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/contributors","subscribers_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/subscribers","subscription_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/subscription","commits_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/commits{/sha}","git_commits_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/commits{/sha}","comments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/comments{/number}","issue_comment_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/comments{/number}","contents_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/contents/{+path}","compare_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/merges","archive_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/downloads","issues_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues{/number}","pulls_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls{/number}","milestones_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/milestones{/number}","notifications_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/labels{/name}","releases_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/releases{/id}","deployments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/deployments","created_at":"2012-12-06T13:58:52Z","updated_at":"2016-02-03T23:52:37Z","pushed_at":"2016-09-12T18:22:57Z","git_url":"git://github.com/GDG-Ukraine/gdg.org.ua.git","ssh_url":"git@github.com:GDG-Ukraine/gdg.org.ua.git","clone_url":"https://github.com/GDG-Ukraine/gdg.org.ua.git","svn_url":"https://github.com/GDG-Ukraine/gdg.org.ua","homepage":"http://gdg.org.ua/","size":870,"stargazers_count":5,"watchers_count":5,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":40,"forks":5,"open_issues":40,"watchers":5,"default_branch":"master"}},"base":{"label":"GDG-Ukraine:master","ref":"master","sha":"9a910e74d2ea73e96b3feec02d8412c95e67dbe4","user":{"login":"GDG-Ukraine","id":2266906,"avatar_url":"https://avatars.githubusercontent.com/u/2266906?v=3","gravatar_id":"","url":"https://api.github.com/users/GDG-Ukraine","html_url":"https://github.com/GDG-Ukraine","followers_url":"https://api.github.com/users/GDG-Ukraine/followers","following_url":"https://api.github.com/users/GDG-Ukraine/following{/other_user}","gists_url":"https://api.github.com/users/GDG-Ukraine/gists{/gist_id}","starred_url":"https://api.github.com/users/GDG-Ukraine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GDG-Ukraine/subscriptions","organizations_url":"https://api.github.com/users/GDG-Ukraine/orgs","repos_url":"https://api.github.com/users/GDG-Ukraine/repos","events_url":"https://api.github.com/users/GDG-Ukraine/events{/privacy}","received_events_url":"https://api.github.com/users/GDG-Ukraine/received_events","type":"Organization","site_admin":false},"repo":{"id":7036517,"name":"gdg.org.ua","full_name":"GDG-Ukraine/gdg.org.ua","owner":{"login":"GDG-Ukraine","id":2266906,"avatar_url":"https://avatars.githubusercontent.com/u/2266906?v=3","gravatar_id":"","url":"https://api.github.com/users/GDG-Ukraine","html_url":"https://github.com/GDG-Ukraine","followers_url":"https://api.github.com/users/GDG-Ukraine/followers","following_url":"https://api.github.com/users/GDG-Ukraine/following{/other_user}","gists_url":"https://api.github.com/users/GDG-Ukraine/gists{/gist_id}","starred_url":"https://api.github.com/users/GDG-Ukraine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/GDG-Ukraine/subscriptions","organizations_url":"https://api.github.com/users/GDG-Ukraine/orgs","repos_url":"https://api.github.com/users/GDG-Ukraine/repos","events_url":"https://api.github.com/users/GDG-Ukraine/events{/privacy}","received_events_url":"https://api.github.com/users/GDG-Ukraine/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/GDG-Ukraine/gdg.org.ua","description":"GDG Ukraine website, event registration forms.","fork":false,"url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua","forks_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/forks","keys_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/keys{/key_id}","collaborators_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/teams","hooks_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/hooks","issue_events_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/events{/number}","events_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/events","assignees_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/assignees{/user}","branches_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/branches{/branch}","tags_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/tags","blobs_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/refs{/sha}","trees_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/trees{/sha}","statuses_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/statuses/{sha}","languages_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/languages","stargazers_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/stargazers","contributors_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/contributors","subscribers_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/subscribers","subscription_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/subscription","commits_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/commits{/sha}","git_commits_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/git/commits{/sha}","comments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/comments{/number}","issue_comment_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/comments{/number}","contents_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/contents/{+path}","compare_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/compare/{base}...{head}","merges_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/merges","archive_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/downloads","issues_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues{/number}","pulls_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls{/number}","milestones_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/milestones{/number}","notifications_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/labels{/name}","releases_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/releases{/id}","deployments_url":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/deployments","created_at":"2012-12-06T13:58:52Z","updated_at":"2016-02-03T23:52:37Z","pushed_at":"2016-09-12T18:22:57Z","git_url":"git://github.com/GDG-Ukraine/gdg.org.ua.git","ssh_url":"git@github.com:GDG-Ukraine/gdg.org.ua.git","clone_url":"https://github.com/GDG-Ukraine/gdg.org.ua.git","svn_url":"https://github.com/GDG-Ukraine/gdg.org.ua","homepage":"http://gdg.org.ua/","size":870,"stargazers_count":5,"watchers_count":5,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":5,"mirror_url":null,"open_issues_count":40,"forks":5,"open_issues":40,"watchers":5,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113"},"html":{"href":"https://github.com/GDG-Ukraine/gdg.org.ua/pull/113"},"issue":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/113"},"comments":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/issues/113/comments"},"review_comments":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113/comments"},"review_comment":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/pulls/113/commits"},"statuses":{"href":"https://api.github.com/repos/GDG-Ukraine/gdg.org.ua/statuses/3cda115b189443873d641c7cb79a8432ae99e92d"}}}}
{"actor":{"display_login":"codacy-bot"}}