{"action":"created","comment":{"url":"https://api.github.com/repos/huge-success/sanic/pulls/comments/232295779","pull_request_review_id":173465489,"id":232295779,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIzMjI5NTc3OQ==","diff_hunk":"@@ -0,0 +1,93 @@\n+class BlueprintGroup(object):\n+    \"\"\"\n+    This class provides a mechanism to implement a Blueprint Group\n+    using the `Blueprint.group` method. To avoid having to re-write\n+    some of the existing implementation, this class provides a custom\n+    iterator implementation that will let you use the object of this\n+    class as a list/tuple inside the existing implementation.\n+    \"\"\"\n+\n+    def __init__(self, url_prefix=None):\n+        \"\"\"\n+        Create a new Blueprint Group\n+\n+        :param url_prefix: URL: to be prefixed before all the Blueprint Prefix\n+        \"\"\"\n+        self._blueprints = list()\n+        self._iter_position = 0\n+        self._url_prefix = url_prefix\n+\n+    @property\n+    def url_prefix(self):\n+        \"\"\"\n+        Retrieve the URL prefix being used for the Current Blueprint Group\n+        :return: string with url prefix\n+        \"\"\"\n+        return self._url_prefix\n+\n+    @property\n+    def blueprints(self):\n+        \"\"\"\n+        Retrieve a list of all the available blueprints under this group.\n+        :return: List of Blueprint instance\n+        \"\"\"\n+        return self._blueprints\n+\n+    @blueprints.setter\n+    def blueprints(self, blueprint):\n+        \"\"\"\n+        Add a new Blueprint to the Group under consideration.\n+        :param blueprint: Instance of Blueprint\n+        :return: None\n+        \"\"\"\n+        self._blueprints.append(blueprint)\n+\n+    def __iter__(self):\n+        \"\"\"Tun the class Blueprint Group into an Iterable item\"\"\"\n+        return self\n+\n+    def __next__(self):","path":"sanic/blueprint_group.py","position":49,"original_position":49,"commit_id":"7e86025de047c374451e658f7bc852ad77133a63","original_commit_id":"39b57ceda986e9ecffc986bffb7c4e0088419409","user":{"login":"yunstanford","id":13110231,"node_id":"MDQ6VXNlcjEzMTEwMjMx","avatar_url":"https://avatars0.githubusercontent.com/u/13110231?v=4","gravatar_id":"","url":"https://api.github.com/users/yunstanford","html_url":"https://github.com/yunstanford","followers_url":"https://api.github.com/users/yunstanford/followers","following_url":"https://api.github.com/users/yunstanford/following{/other_user}","gists_url":"https://api.github.com/users/yunstanford/gists{/gist_id}","starred_url":"https://api.github.com/users/yunstanford/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/yunstanford/subscriptions","organizations_url":"https://api.github.com/users/yunstanford/orgs","repos_url":"https://api.github.com/users/yunstanford/repos","events_url":"https://api.github.com/users/yunstanford/events{/privacy}","received_events_url":"https://api.github.com/users/yunstanford/received_events","type":"User","site_admin":false},"body":"It'll raise `StopIteration` when exhausted all items. `iter([])` basically returns an iterator.","created_at":"2018-11-09T15:40:25Z","updated_at":"2018-11-09T15:40:25Z","html_url":"https://github.com/huge-success/sanic/pull/1399#discussion_r232295779","pull_request_url":"https://api.github.com/repos/huge-success/sanic/pulls/1399","author_association":"MEMBER","_links":{"self":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/comments/232295779"},"html":{"href":"https://github.com/huge-success/sanic/pull/1399#discussion_r232295779"},"pull_request":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/1399"}},"in_reply_to_id":231928967},"pull_request":{"url":"https://api.github.com/repos/huge-success/sanic/pulls/1399","id":228629434,"node_id":"MDExOlB1bGxSZXF1ZXN0MjI4NjI5NDM0","html_url":"https://github.com/huge-success/sanic/pull/1399","diff_url":"https://github.com/huge-success/sanic/pull/1399.diff","patch_url":"https://github.com/huge-success/sanic/pull/1399.patch","issue_url":"https://api.github.com/repos/huge-success/sanic/issues/1399","number":1399,"state":"open","locked":false,"title":"Enable Middleware Support for Blueprint Groups","user":{"login":"harshanarayana","id":1404867,"node_id":"MDQ6VXNlcjE0MDQ4Njc=","avatar_url":"https://avatars1.githubusercontent.com/u/1404867?v=4","gravatar_id":"","url":"https://api.github.com/users/harshanarayana","html_url":"https://github.com/harshanarayana","followers_url":"https://api.github.com/users/harshanarayana/followers","following_url":"https://api.github.com/users/harshanarayana/following{/other_user}","gists_url":"https://api.github.com/users/harshanarayana/gists{/gist_id}","starred_url":"https://api.github.com/users/harshanarayana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harshanarayana/subscriptions","organizations_url":"https://api.github.com/users/harshanarayana/orgs","repos_url":"https://api.github.com/users/harshanarayana/repos","events_url":"https://api.github.com/users/harshanarayana/events{/privacy}","received_events_url":"https://api.github.com/users/harshanarayana/received_events","type":"User","site_admin":false},"body":"This commit will enable the users to implement a middleware at the blueprint group level whereby enforcing the middleware automatically to each of the available Blueprints that are part of the group.\r\n\r\nThis will enable a simple way in which a certain set of common features and criteria can be enforced on a Blueprint group. i.e. authentication and authorization\r\n\r\nThis commit will address the feature request raised as part of Issue #1386 ","created_at":"2018-11-06T09:48:14Z","updated_at":"2018-11-09T15:40:25Z","closed_at":null,"merged_at":null,"merge_commit_sha":"f1ff1b0e202aded81aeef483ef17e70ffc623f1e","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":{"url":"https://api.github.com/repos/huge-success/sanic/milestones/15","html_url":"https://github.com/huge-success/sanic/milestone/15","labels_url":"https://api.github.com/repos/huge-success/sanic/milestones/15/labels","id":3691989,"node_id":"MDk6TWlsZXN0b25lMzY5MTk4OQ==","number":15,"title":"19.03","description":null,"creator":{"login":"sjsadowski","id":857480,"node_id":"MDQ6VXNlcjg1NzQ4MA==","avatar_url":"https://avatars3.githubusercontent.com/u/857480?v=4","gravatar_id":"","url":"https://api.github.com/users/sjsadowski","html_url":"https://github.com/sjsadowski","followers_url":"https://api.github.com/users/sjsadowski/followers","following_url":"https://api.github.com/users/sjsadowski/following{/other_user}","gists_url":"https://api.github.com/users/sjsadowski/gists{/gist_id}","starred_url":"https://api.github.com/users/sjsadowski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/sjsadowski/subscriptions","organizations_url":"https://api.github.com/users/sjsadowski/orgs","repos_url":"https://api.github.com/users/sjsadowski/repos","events_url":"https://api.github.com/users/sjsadowski/events{/privacy}","received_events_url":"https://api.github.com/users/sjsadowski/received_events","type":"User","site_admin":false},"open_issues":6,"closed_issues":0,"state":"open","created_at":"2018-09-27T00:59:03Z","updated_at":"2018-11-06T14:40:08Z","due_on":null,"closed_at":null},"commits_url":"https://api.github.com/repos/huge-success/sanic/pulls/1399/commits","review_comments_url":"https://api.github.com/repos/huge-success/sanic/pulls/1399/comments","review_comment_url":"https://api.github.com/repos/huge-success/sanic/pulls/comments{/number}","comments_url":"https://api.github.com/repos/huge-success/sanic/issues/1399/comments","statuses_url":"https://api.github.com/repos/huge-success/sanic/statuses/7e86025de047c374451e658f7bc852ad77133a63","head":{"label":"harshanarayana:feature/GIT-1386_Enable_Blueprint_group_middlewares","ref":"feature/GIT-1386_Enable_Blueprint_group_middlewares","sha":"7e86025de047c374451e658f7bc852ad77133a63","user":{"login":"harshanarayana","id":1404867,"node_id":"MDQ6VXNlcjE0MDQ4Njc=","avatar_url":"https://avatars1.githubusercontent.com/u/1404867?v=4","gravatar_id":"","url":"https://api.github.com/users/harshanarayana","html_url":"https://github.com/harshanarayana","followers_url":"https://api.github.com/users/harshanarayana/followers","following_url":"https://api.github.com/users/harshanarayana/following{/other_user}","gists_url":"https://api.github.com/users/harshanarayana/gists{/gist_id}","starred_url":"https://api.github.com/users/harshanarayana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harshanarayana/subscriptions","organizations_url":"https://api.github.com/users/harshanarayana/orgs","repos_url":"https://api.github.com/users/harshanarayana/repos","events_url":"https://api.github.com/users/harshanarayana/events{/privacy}","received_events_url":"https://api.github.com/users/harshanarayana/received_events","type":"User","site_admin":false},"repo":{"id":156220121,"node_id":"MDEwOlJlcG9zaXRvcnkxNTYyMjAxMjE=","name":"sanic","full_name":"harshanarayana/sanic","private":false,"owner":{"login":"harshanarayana","id":1404867,"node_id":"MDQ6VXNlcjE0MDQ4Njc=","avatar_url":"https://avatars1.githubusercontent.com/u/1404867?v=4","gravatar_id":"","url":"https://api.github.com/users/harshanarayana","html_url":"https://github.com/harshanarayana","followers_url":"https://api.github.com/users/harshanarayana/followers","following_url":"https://api.github.com/users/harshanarayana/following{/other_user}","gists_url":"https://api.github.com/users/harshanarayana/gists{/gist_id}","starred_url":"https://api.github.com/users/harshanarayana/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/harshanarayana/subscriptions","organizations_url":"https://api.github.com/users/harshanarayana/orgs","repos_url":"https://api.github.com/users/harshanarayana/repos","events_url":"https://api.github.com/users/harshanarayana/events{/privacy}","received_events_url":"https://api.github.com/users/harshanarayana/received_events","type":"User","site_admin":false},"html_url":"https://github.com/harshanarayana/sanic","description":"Async Python 3.5+ web server that's written to go fast","fork":true,"url":"https://api.github.com/repos/harshanarayana/sanic","forks_url":"https://api.github.com/repos/harshanarayana/sanic/forks","keys_url":"https://api.github.com/repos/harshanarayana/sanic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/harshanarayana/sanic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/harshanarayana/sanic/teams","hooks_url":"https://api.github.com/repos/harshanarayana/sanic/hooks","issue_events_url":"https://api.github.com/repos/harshanarayana/sanic/issues/events{/number}","events_url":"https://api.github.com/repos/harshanarayana/sanic/events","assignees_url":"https://api.github.com/repos/harshanarayana/sanic/assignees{/user}","branches_url":"https://api.github.com/repos/harshanarayana/sanic/branches{/branch}","tags_url":"https://api.github.com/repos/harshanarayana/sanic/tags","blobs_url":"https://api.github.com/repos/harshanarayana/sanic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/harshanarayana/sanic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/harshanarayana/sanic/git/refs{/sha}","trees_url":"https://api.github.com/repos/harshanarayana/sanic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/harshanarayana/sanic/statuses/{sha}","languages_url":"https://api.github.com/repos/harshanarayana/sanic/languages","stargazers_url":"https://api.github.com/repos/harshanarayana/sanic/stargazers","contributors_url":"https://api.github.com/repos/harshanarayana/sanic/contributors","subscribers_url":"https://api.github.com/repos/harshanarayana/sanic/subscribers","subscription_url":"https://api.github.com/repos/harshanarayana/sanic/subscription","commits_url":"https://api.github.com/repos/harshanarayana/sanic/commits{/sha}","git_commits_url":"https://api.github.com/repos/harshanarayana/sanic/git/commits{/sha}","comments_url":"https://api.github.com/repos/harshanarayana/sanic/comments{/number}","issue_comment_url":"https://api.github.com/repos/harshanarayana/sanic/issues/comments{/number}","contents_url":"https://api.github.com/repos/harshanarayana/sanic/contents/{+path}","compare_url":"https://api.github.com/repos/harshanarayana/sanic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/harshanarayana/sanic/merges","archive_url":"https://api.github.com/repos/harshanarayana/sanic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/harshanarayana/sanic/downloads","issues_url":"https://api.github.com/repos/harshanarayana/sanic/issues{/number}","pulls_url":"https://api.github.com/repos/harshanarayana/sanic/pulls{/number}","milestones_url":"https://api.github.com/repos/harshanarayana/sanic/milestones{/number}","notifications_url":"https://api.github.com/repos/harshanarayana/sanic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/harshanarayana/sanic/labels{/name}","releases_url":"https://api.github.com/repos/harshanarayana/sanic/releases{/id}","deployments_url":"https://api.github.com/repos/harshanarayana/sanic/deployments","created_at":"2018-11-05T13:13:27Z","updated_at":"2018-11-07T15:42:14Z","pushed_at":"2018-11-08T16:32:11Z","git_url":"git://github.com/harshanarayana/sanic.git","ssh_url":"git@github.com:harshanarayana/sanic.git","clone_url":"https://github.com/harshanarayana/sanic.git","svn_url":"https://github.com/harshanarayana/sanic","homepage":"https://sanicframework.org/","size":1719,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"huge-success:master","ref":"master","sha":"0e9f3509822a63d373b7b639904f1632c64efc38","user":{"login":"huge-success","id":25215992,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MjE1OTky","avatar_url":"https://avatars0.githubusercontent.com/u/25215992?v=4","gravatar_id":"","url":"https://api.github.com/users/huge-success","html_url":"https://github.com/huge-success","followers_url":"https://api.github.com/users/huge-success/followers","following_url":"https://api.github.com/users/huge-success/following{/other_user}","gists_url":"https://api.github.com/users/huge-success/gists{/gist_id}","starred_url":"https://api.github.com/users/huge-success/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huge-success/subscriptions","organizations_url":"https://api.github.com/users/huge-success/orgs","repos_url":"https://api.github.com/users/huge-success/repos","events_url":"https://api.github.com/users/huge-success/events{/privacy}","received_events_url":"https://api.github.com/users/huge-success/received_events","type":"Organization","site_admin":false},"repo":{"id":59720190,"node_id":"MDEwOlJlcG9zaXRvcnk1OTcyMDE5MA==","name":"sanic","full_name":"huge-success/sanic","private":false,"owner":{"login":"huge-success","id":25215992,"node_id":"MDEyOk9yZ2FuaXphdGlvbjI1MjE1OTky","avatar_url":"https://avatars0.githubusercontent.com/u/25215992?v=4","gravatar_id":"","url":"https://api.github.com/users/huge-success","html_url":"https://github.com/huge-success","followers_url":"https://api.github.com/users/huge-success/followers","following_url":"https://api.github.com/users/huge-success/following{/other_user}","gists_url":"https://api.github.com/users/huge-success/gists{/gist_id}","starred_url":"https://api.github.com/users/huge-success/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/huge-success/subscriptions","organizations_url":"https://api.github.com/users/huge-success/orgs","repos_url":"https://api.github.com/users/huge-success/repos","events_url":"https://api.github.com/users/huge-success/events{/privacy}","received_events_url":"https://api.github.com/users/huge-success/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/huge-success/sanic","description":"Async Python 3.5+ web server that's written to go fast","fork":false,"url":"https://api.github.com/repos/huge-success/sanic","forks_url":"https://api.github.com/repos/huge-success/sanic/forks","keys_url":"https://api.github.com/repos/huge-success/sanic/keys{/key_id}","collaborators_url":"https://api.github.com/repos/huge-success/sanic/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/huge-success/sanic/teams","hooks_url":"https://api.github.com/repos/huge-success/sanic/hooks","issue_events_url":"https://api.github.com/repos/huge-success/sanic/issues/events{/number}","events_url":"https://api.github.com/repos/huge-success/sanic/events","assignees_url":"https://api.github.com/repos/huge-success/sanic/assignees{/user}","branches_url":"https://api.github.com/repos/huge-success/sanic/branches{/branch}","tags_url":"https://api.github.com/repos/huge-success/sanic/tags","blobs_url":"https://api.github.com/repos/huge-success/sanic/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/huge-success/sanic/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/huge-success/sanic/git/refs{/sha}","trees_url":"https://api.github.com/repos/huge-success/sanic/git/trees{/sha}","statuses_url":"https://api.github.com/repos/huge-success/sanic/statuses/{sha}","languages_url":"https://api.github.com/repos/huge-success/sanic/languages","stargazers_url":"https://api.github.com/repos/huge-success/sanic/stargazers","contributors_url":"https://api.github.com/repos/huge-success/sanic/contributors","subscribers_url":"https://api.github.com/repos/huge-success/sanic/subscribers","subscription_url":"https://api.github.com/repos/huge-success/sanic/subscription","commits_url":"https://api.github.com/repos/huge-success/sanic/commits{/sha}","git_commits_url":"https://api.github.com/repos/huge-success/sanic/git/commits{/sha}","comments_url":"https://api.github.com/repos/huge-success/sanic/comments{/number}","issue_comment_url":"https://api.github.com/repos/huge-success/sanic/issues/comments{/number}","contents_url":"https://api.github.com/repos/huge-success/sanic/contents/{+path}","compare_url":"https://api.github.com/repos/huge-success/sanic/compare/{base}...{head}","merges_url":"https://api.github.com/repos/huge-success/sanic/merges","archive_url":"https://api.github.com/repos/huge-success/sanic/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/huge-success/sanic/downloads","issues_url":"https://api.github.com/repos/huge-success/sanic/issues{/number}","pulls_url":"https://api.github.com/repos/huge-success/sanic/pulls{/number}","milestones_url":"https://api.github.com/repos/huge-success/sanic/milestones{/number}","notifications_url":"https://api.github.com/repos/huge-success/sanic/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/huge-success/sanic/labels{/name}","releases_url":"https://api.github.com/repos/huge-success/sanic/releases{/id}","deployments_url":"https://api.github.com/repos/huge-success/sanic/deployments","created_at":"2016-05-26T04:38:22Z","updated_at":"2018-11-09T13:49:01Z","pushed_at":"2018-11-09T04:49:14Z","git_url":"git://github.com/huge-success/sanic.git","ssh_url":"git@github.com:huge-success/sanic.git","clone_url":"https://github.com/huge-success/sanic.git","svn_url":"https://github.com/huge-success/sanic","homepage":"https://sanicframework.org/","size":1682,"stargazers_count":10617,"watchers_count":10617,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1013,"mirror_url":null,"archived":false,"open_issues_count":130,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":1013,"open_issues":130,"watchers":10617,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/1399"},"html":{"href":"https://github.com/huge-success/sanic/pull/1399"},"issue":{"href":"https://api.github.com/repos/huge-success/sanic/issues/1399"},"comments":{"href":"https://api.github.com/repos/huge-success/sanic/issues/1399/comments"},"review_comments":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/1399/comments"},"review_comment":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/huge-success/sanic/pulls/1399/commits"},"statuses":{"href":"https://api.github.com/repos/huge-success/sanic/statuses/7e86025de047c374451e658f7bc852ad77133a63"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"yunstanford"}}