{"action":"created","comment":{"url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/comments/78297628","id":78297628,"diff_hunk":"@@ -0,0 +1,159 @@\n+from flask import Flask, jsonify, request, render_template, redirect, make_response, flash, Response\n+from flask_restful import abort, Api, Resource\n+from flask_login import login_user, logout_user, login_required, current_user\n+from webargs import fields\n+from webargs.flaskparser import use_args\n+import os\n+import json\n+import logging\n+\n+from authenticators import FileAuthenticator\n+from authorizers import FileAuthorizer\n+from resources import Users, Groups, CanActAsUsers\n+from sessions import login_manager, SessionUser\n+import sessions\n+","path":"aaad/aaad_app.py","position":15,"original_position":15,"commit_id":"f111a0efd9c5c602829f57e9f59ad005b8bc62e4","original_commit_id":"f111a0efd9c5c602829f57e9f59ad005b8bc62e4","user":{"login":"miroswan","id":3710241,"avatar_url":"https://avatars.githubusercontent.com/u/3710241?v=3","gravatar_id":"","url":"https://api.github.com/users/miroswan","html_url":"https://github.com/miroswan","followers_url":"https://api.github.com/users/miroswan/followers","following_url":"https://api.github.com/users/miroswan/following{/other_user}","gists_url":"https://api.github.com/users/miroswan/gists{/gist_id}","starred_url":"https://api.github.com/users/miroswan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/miroswan/subscriptions","organizations_url":"https://api.github.com/users/miroswan/orgs","repos_url":"https://api.github.com/users/miroswan/repos","events_url":"https://api.github.com/users/miroswan/events{/privacy}","received_events_url":"https://api.github.com/users/miroswan/received_events","type":"User","site_admin":false},"body":"There is a redundant import here. Also, I believe it's best practice to prepend each imported module with a dot character when doing local imports. \r\n\r\nReference: https://docs.python.org/2.5/whatsnew/pep-328.html","created_at":"2016-09-11T16:00:58Z","updated_at":"2016-09-11T16:00:58Z","html_url":"https://github.com/seomoz/roger-mesos/pull/110#discussion_r78297628","pull_request_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110","_links":{"self":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/comments/78297628"},"html":{"href":"https://github.com/seomoz/roger-mesos/pull/110#discussion_r78297628"},"pull_request":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110"}}},"pull_request":{"url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110","id":83876864,"html_url":"https://github.com/seomoz/roger-mesos/pull/110","diff_url":"https://github.com/seomoz/roger-mesos/pull/110.diff","patch_url":"https://github.com/seomoz/roger-mesos/pull/110.patch","issue_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/110","number":110,"state":"open","locked":false,"title":"simplify and add aaad api","user":{"login":"ankanm","id":558066,"avatar_url":"https://avatars.githubusercontent.com/u/558066?v=3","gravatar_id":"","url":"https://api.github.com/users/ankanm","html_url":"https://github.com/ankanm","followers_url":"https://api.github.com/users/ankanm/followers","following_url":"https://api.github.com/users/ankanm/following{/other_user}","gists_url":"https://api.github.com/users/ankanm/gists{/gist_id}","starred_url":"https://api.github.com/users/ankanm/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ankanm/subscriptions","organizations_url":"https://api.github.com/users/ankanm/orgs","repos_url":"https://api.github.com/users/ankanm/repos","events_url":"https://api.github.com/users/ankanm/events{/privacy}","received_events_url":"https://api.github.com/users/ankanm/received_events","type":"User","site_admin":false},"body":"ROGER-1358 and ROGER-1359.\r\n- [x] Create a more standard python project. \r\n- [x] Moving to flask.\r\n- [x] Added UI + better handling of auth etc.\r\n- [x] Simpler/modularized/standard code.\r\n- [x] Cookie/session handling more standard (and more secure than the previous one).\r\n- [x] Update ansible scripts for new setup.\r\n- [x] Change how aaad is started on the server.\r\n- [x] Ensure logging is appropriate.\r\n- [x] Updates to nginx (and test).\r\n- [ ] Remove/deprecate old `aaad.py`\r\n- [ ] More (??)\r\n\r\nThis is ~~still WIP~~ mostly complete and ready for review.\r\n\r\nfyi - @amitbose327 @vmahedia ","created_at":"2016-09-02T23:27:09Z","updated_at":"2016-09-11T16:00:58Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d1f8aedb37a1f4553c7ce93f67aca8a4e8b6caf0","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110/commits","review_comments_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110/comments","review_comment_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls/comments{/number}","comments_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/110/comments","statuses_url":"https://api.github.com/repos/seomoz/roger-mesos/statuses/f111a0efd9c5c602829f57e9f59ad005b8bc62e4","head":{"label":"seomoz:ankan/ROGER-1358-ROGER-1359-simplify-and-add-aaad-api","ref":"ankan/ROGER-1358-ROGER-1359-simplify-and-add-aaad-api","sha":"f111a0efd9c5c602829f57e9f59ad005b8bc62e4","user":{"login":"seomoz","id":104895,"avatar_url":"https://avatars.githubusercontent.com/u/104895?v=3","gravatar_id":"","url":"https://api.github.com/users/seomoz","html_url":"https://github.com/seomoz","followers_url":"https://api.github.com/users/seomoz/followers","following_url":"https://api.github.com/users/seomoz/following{/other_user}","gists_url":"https://api.github.com/users/seomoz/gists{/gist_id}","starred_url":"https://api.github.com/users/seomoz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seomoz/subscriptions","organizations_url":"https://api.github.com/users/seomoz/orgs","repos_url":"https://api.github.com/users/seomoz/repos","events_url":"https://api.github.com/users/seomoz/events{/privacy}","received_events_url":"https://api.github.com/users/seomoz/received_events","type":"Organization","site_admin":false},"repo":{"id":47104887,"name":"roger-mesos","full_name":"seomoz/roger-mesos","owner":{"login":"seomoz","id":104895,"avatar_url":"https://avatars.githubusercontent.com/u/104895?v=3","gravatar_id":"","url":"https://api.github.com/users/seomoz","html_url":"https://github.com/seomoz","followers_url":"https://api.github.com/users/seomoz/followers","following_url":"https://api.github.com/users/seomoz/following{/other_user}","gists_url":"https://api.github.com/users/seomoz/gists{/gist_id}","starred_url":"https://api.github.com/users/seomoz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seomoz/subscriptions","organizations_url":"https://api.github.com/users/seomoz/orgs","repos_url":"https://api.github.com/users/seomoz/repos","events_url":"https://api.github.com/users/seomoz/events{/privacy}","received_events_url":"https://api.github.com/users/seomoz/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seomoz/roger-mesos","description":"A complete mesos cluster setup with automatic load balancing","fork":false,"url":"https://api.github.com/repos/seomoz/roger-mesos","forks_url":"https://api.github.com/repos/seomoz/roger-mesos/forks","keys_url":"https://api.github.com/repos/seomoz/roger-mesos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seomoz/roger-mesos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seomoz/roger-mesos/teams","hooks_url":"https://api.github.com/repos/seomoz/roger-mesos/hooks","issue_events_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/events{/number}","events_url":"https://api.github.com/repos/seomoz/roger-mesos/events","assignees_url":"https://api.github.com/repos/seomoz/roger-mesos/assignees{/user}","branches_url":"https://api.github.com/repos/seomoz/roger-mesos/branches{/branch}","tags_url":"https://api.github.com/repos/seomoz/roger-mesos/tags","blobs_url":"https://api.github.com/repos/seomoz/roger-mesos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seomoz/roger-mesos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seomoz/roger-mesos/git/refs{/sha}","trees_url":"https://api.github.com/repos/seomoz/roger-mesos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seomoz/roger-mesos/statuses/{sha}","languages_url":"https://api.github.com/repos/seomoz/roger-mesos/languages","stargazers_url":"https://api.github.com/repos/seomoz/roger-mesos/stargazers","contributors_url":"https://api.github.com/repos/seomoz/roger-mesos/contributors","subscribers_url":"https://api.github.com/repos/seomoz/roger-mesos/subscribers","subscription_url":"https://api.github.com/repos/seomoz/roger-mesos/subscription","commits_url":"https://api.github.com/repos/seomoz/roger-mesos/commits{/sha}","git_commits_url":"https://api.github.com/repos/seomoz/roger-mesos/git/commits{/sha}","comments_url":"https://api.github.com/repos/seomoz/roger-mesos/comments{/number}","issue_comment_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/comments{/number}","contents_url":"https://api.github.com/repos/seomoz/roger-mesos/contents/{+path}","compare_url":"https://api.github.com/repos/seomoz/roger-mesos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seomoz/roger-mesos/merges","archive_url":"https://api.github.com/repos/seomoz/roger-mesos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seomoz/roger-mesos/downloads","issues_url":"https://api.github.com/repos/seomoz/roger-mesos/issues{/number}","pulls_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls{/number}","milestones_url":"https://api.github.com/repos/seomoz/roger-mesos/milestones{/number}","notifications_url":"https://api.github.com/repos/seomoz/roger-mesos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seomoz/roger-mesos/labels{/name}","releases_url":"https://api.github.com/repos/seomoz/roger-mesos/releases{/id}","deployments_url":"https://api.github.com/repos/seomoz/roger-mesos/deployments","created_at":"2015-11-30T08:24:43Z","updated_at":"2016-04-22T23:00:34Z","pushed_at":"2016-09-11T03:56:23Z","git_url":"git://github.com/seomoz/roger-mesos.git","ssh_url":"git@github.com:seomoz/roger-mesos.git","clone_url":"https://github.com/seomoz/roger-mesos.git","svn_url":"https://github.com/seomoz/roger-mesos","homepage":"","size":19215,"stargazers_count":7,"watchers_count":7,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":8,"forks":4,"open_issues":8,"watchers":7,"default_branch":"master"}},"base":{"label":"seomoz:master","ref":"master","sha":"e61897f70d46825a82be07488441e1f100e21990","user":{"login":"seomoz","id":104895,"avatar_url":"https://avatars.githubusercontent.com/u/104895?v=3","gravatar_id":"","url":"https://api.github.com/users/seomoz","html_url":"https://github.com/seomoz","followers_url":"https://api.github.com/users/seomoz/followers","following_url":"https://api.github.com/users/seomoz/following{/other_user}","gists_url":"https://api.github.com/users/seomoz/gists{/gist_id}","starred_url":"https://api.github.com/users/seomoz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seomoz/subscriptions","organizations_url":"https://api.github.com/users/seomoz/orgs","repos_url":"https://api.github.com/users/seomoz/repos","events_url":"https://api.github.com/users/seomoz/events{/privacy}","received_events_url":"https://api.github.com/users/seomoz/received_events","type":"Organization","site_admin":false},"repo":{"id":47104887,"name":"roger-mesos","full_name":"seomoz/roger-mesos","owner":{"login":"seomoz","id":104895,"avatar_url":"https://avatars.githubusercontent.com/u/104895?v=3","gravatar_id":"","url":"https://api.github.com/users/seomoz","html_url":"https://github.com/seomoz","followers_url":"https://api.github.com/users/seomoz/followers","following_url":"https://api.github.com/users/seomoz/following{/other_user}","gists_url":"https://api.github.com/users/seomoz/gists{/gist_id}","starred_url":"https://api.github.com/users/seomoz/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/seomoz/subscriptions","organizations_url":"https://api.github.com/users/seomoz/orgs","repos_url":"https://api.github.com/users/seomoz/repos","events_url":"https://api.github.com/users/seomoz/events{/privacy}","received_events_url":"https://api.github.com/users/seomoz/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/seomoz/roger-mesos","description":"A complete mesos cluster setup with automatic load balancing","fork":false,"url":"https://api.github.com/repos/seomoz/roger-mesos","forks_url":"https://api.github.com/repos/seomoz/roger-mesos/forks","keys_url":"https://api.github.com/repos/seomoz/roger-mesos/keys{/key_id}","collaborators_url":"https://api.github.com/repos/seomoz/roger-mesos/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/seomoz/roger-mesos/teams","hooks_url":"https://api.github.com/repos/seomoz/roger-mesos/hooks","issue_events_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/events{/number}","events_url":"https://api.github.com/repos/seomoz/roger-mesos/events","assignees_url":"https://api.github.com/repos/seomoz/roger-mesos/assignees{/user}","branches_url":"https://api.github.com/repos/seomoz/roger-mesos/branches{/branch}","tags_url":"https://api.github.com/repos/seomoz/roger-mesos/tags","blobs_url":"https://api.github.com/repos/seomoz/roger-mesos/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/seomoz/roger-mesos/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/seomoz/roger-mesos/git/refs{/sha}","trees_url":"https://api.github.com/repos/seomoz/roger-mesos/git/trees{/sha}","statuses_url":"https://api.github.com/repos/seomoz/roger-mesos/statuses/{sha}","languages_url":"https://api.github.com/repos/seomoz/roger-mesos/languages","stargazers_url":"https://api.github.com/repos/seomoz/roger-mesos/stargazers","contributors_url":"https://api.github.com/repos/seomoz/roger-mesos/contributors","subscribers_url":"https://api.github.com/repos/seomoz/roger-mesos/subscribers","subscription_url":"https://api.github.com/repos/seomoz/roger-mesos/subscription","commits_url":"https://api.github.com/repos/seomoz/roger-mesos/commits{/sha}","git_commits_url":"https://api.github.com/repos/seomoz/roger-mesos/git/commits{/sha}","comments_url":"https://api.github.com/repos/seomoz/roger-mesos/comments{/number}","issue_comment_url":"https://api.github.com/repos/seomoz/roger-mesos/issues/comments{/number}","contents_url":"https://api.github.com/repos/seomoz/roger-mesos/contents/{+path}","compare_url":"https://api.github.com/repos/seomoz/roger-mesos/compare/{base}...{head}","merges_url":"https://api.github.com/repos/seomoz/roger-mesos/merges","archive_url":"https://api.github.com/repos/seomoz/roger-mesos/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/seomoz/roger-mesos/downloads","issues_url":"https://api.github.com/repos/seomoz/roger-mesos/issues{/number}","pulls_url":"https://api.github.com/repos/seomoz/roger-mesos/pulls{/number}","milestones_url":"https://api.github.com/repos/seomoz/roger-mesos/milestones{/number}","notifications_url":"https://api.github.com/repos/seomoz/roger-mesos/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/seomoz/roger-mesos/labels{/name}","releases_url":"https://api.github.com/repos/seomoz/roger-mesos/releases{/id}","deployments_url":"https://api.github.com/repos/seomoz/roger-mesos/deployments","created_at":"2015-11-30T08:24:43Z","updated_at":"2016-04-22T23:00:34Z","pushed_at":"2016-09-11T03:56:23Z","git_url":"git://github.com/seomoz/roger-mesos.git","ssh_url":"git@github.com:seomoz/roger-mesos.git","clone_url":"https://github.com/seomoz/roger-mesos.git","svn_url":"https://github.com/seomoz/roger-mesos","homepage":"","size":19215,"stargazers_count":7,"watchers_count":7,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":4,"mirror_url":null,"open_issues_count":8,"forks":4,"open_issues":8,"watchers":7,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110"},"html":{"href":"https://github.com/seomoz/roger-mesos/pull/110"},"issue":{"href":"https://api.github.com/repos/seomoz/roger-mesos/issues/110"},"comments":{"href":"https://api.github.com/repos/seomoz/roger-mesos/issues/110/comments"},"review_comments":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110/comments"},"review_comment":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/seomoz/roger-mesos/pulls/110/commits"},"statuses":{"href":"https://api.github.com/repos/seomoz/roger-mesos/statuses/f111a0efd9c5c602829f57e9f59ad005b8bc62e4"}}}}
{"actor":{"display_login":"miroswan"}}