{"action":"created","comment":{"url":"https://api.github.com/repos/python/peps/pulls/comments/79799655","id":79799655,"diff_hunk":"@@ -1647,15 +1720,31 @@ callback-based frameworks like Twisted.  After converting a coroutine\n into a Task, callbacks can be added to the Task.\n \n To convert a coroutine into a task, call the coroutine function and\n-pass the resulting coroutine object to the ``asyncio.Task()``\n-constructor.  You may also use ``asyncio.async()`` for this purpose.\n+pass the resulting coroutine object to the ``loop.create_task()``\n+method.  You may also use ``asyncio.ensure_future()`` for this purpose.\n \n You may ask, why not automatically convert all coroutines to Tasks?\n The ``@asyncio.coroutine`` decorator could do this.  However, this would\n slow things down considerably in the case where one coroutine calls\n another (and so on), as switching to a \"bare\" coroutine has much less\n overhead than switching to a Task.\n \n+A Task is inherited from ``Future`` but adds new methods:","path":"pep-3156.txt","position":169,"original_position":169,"commit_id":"82396eae3b78831664d7acf7e34faa34a0467d95","original_commit_id":"82396eae3b78831664d7acf7e34faa34a0467d95","user":{"login":"asvetlov","id":356399,"avatar_url":"https://avatars.githubusercontent.com/u/356399?v=3","gravatar_id":"","url":"https://api.github.com/users/asvetlov","html_url":"https://github.com/asvetlov","followers_url":"https://api.github.com/users/asvetlov/followers","following_url":"https://api.github.com/users/asvetlov/following{/other_user}","gists_url":"https://api.github.com/users/asvetlov/gists{/gist_id}","starred_url":"https://api.github.com/users/asvetlov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asvetlov/subscriptions","organizations_url":"https://api.github.com/users/asvetlov/orgs","repos_url":"https://api.github.com/users/asvetlov/repos","events_url":"https://api.github.com/users/asvetlov/events{/privacy}","received_events_url":"https://api.github.com/users/asvetlov/received_events","type":"User","site_admin":false},"body":"In asyncio Task is technically derived from `Future` but in pep we can declare it a *future-compatibe* with explicit enumeration of required/supported methods.\r\n\r\nI heard very many times how people are confusing by Future->Task inheritance.\r\nIt makes sense for asyncio implementation but mentally Task and Future are different flavors of async development style.\r\n\r\nMoreover end asyncio user usually never works with futures explicitly but operates on tasks only.","created_at":"2016-09-21T10:05:23Z","updated_at":"2016-09-21T10:05:23Z","html_url":"https://github.com/python/peps/pull/105#discussion_r79799655","pull_request_url":"https://api.github.com/repos/python/peps/pulls/105","_links":{"self":{"href":"https://api.github.com/repos/python/peps/pulls/comments/79799655"},"html":{"href":"https://github.com/python/peps/pull/105#discussion_r79799655"},"pull_request":{"href":"https://api.github.com/repos/python/peps/pulls/105"}}},"pull_request":{"url":"https://api.github.com/repos/python/peps/pulls/105","id":85828006,"html_url":"https://github.com/python/peps/pull/105","diff_url":"https://github.com/python/peps/pull/105.diff","patch_url":"https://github.com/python/peps/pull/105.patch","issue_url":"https://api.github.com/repos/python/peps/issues/105","number":105,"state":"open","locked":false,"title":"WIP for asyncio PEP update (not finished yet)","user":{"login":"asvetlov","id":356399,"avatar_url":"https://avatars.githubusercontent.com/u/356399?v=3","gravatar_id":"","url":"https://api.github.com/users/asvetlov","html_url":"https://github.com/asvetlov","followers_url":"https://api.github.com/users/asvetlov/followers","following_url":"https://api.github.com/users/asvetlov/following{/other_user}","gists_url":"https://api.github.com/users/asvetlov/gists{/gist_id}","starred_url":"https://api.github.com/users/asvetlov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asvetlov/subscriptions","organizations_url":"https://api.github.com/users/asvetlov/orgs","repos_url":"https://api.github.com/users/asvetlov/repos","events_url":"https://api.github.com/users/asvetlov/events{/privacy}","received_events_url":"https://api.github.com/users/asvetlov/received_events","type":"User","site_admin":false},"body":"@gvanrossum @1st1 the work is still in progress, sorry.\r\n\r\nBut I need your advice.\r\n\r\nShould the PEP reflect the following:\r\n* child watchers in loop policy\r\n* strong list of *context keys* supported by `loop.call_exception_handler(context)`\r\n* strong list of *names* supported by `transport.get_extra_info()`\r\n* Task's methods like `get_stack()` and `print_stack()`\r\n\r\nI would appreciate the careful review of existing changes as well.\r\n\r\nP.S.\r\n@bdarnell had asked me to let him involved into the PEP update.\r\nHi've asked to mention @glyph also.","created_at":"2016-09-19T16:41:09Z","updated_at":"2016-09-21T10:05:23Z","closed_at":null,"merged_at":null,"merge_commit_sha":"d5f1cd3f3a5158e4a8cb601741f7a0dd299b2e4e","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/python/peps/pulls/105/commits","review_comments_url":"https://api.github.com/repos/python/peps/pulls/105/comments","review_comment_url":"https://api.github.com/repos/python/peps/pulls/comments{/number}","comments_url":"https://api.github.com/repos/python/peps/issues/105/comments","statuses_url":"https://api.github.com/repos/python/peps/statuses/82396eae3b78831664d7acf7e34faa34a0467d95","head":{"label":"asvetlov:master","ref":"master","sha":"82396eae3b78831664d7acf7e34faa34a0467d95","user":{"login":"asvetlov","id":356399,"avatar_url":"https://avatars.githubusercontent.com/u/356399?v=3","gravatar_id":"","url":"https://api.github.com/users/asvetlov","html_url":"https://github.com/asvetlov","followers_url":"https://api.github.com/users/asvetlov/followers","following_url":"https://api.github.com/users/asvetlov/following{/other_user}","gists_url":"https://api.github.com/users/asvetlov/gists{/gist_id}","starred_url":"https://api.github.com/users/asvetlov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asvetlov/subscriptions","organizations_url":"https://api.github.com/users/asvetlov/orgs","repos_url":"https://api.github.com/users/asvetlov/repos","events_url":"https://api.github.com/users/asvetlov/events{/privacy}","received_events_url":"https://api.github.com/users/asvetlov/received_events","type":"User","site_admin":false},"repo":{"id":68617316,"name":"peps","full_name":"asvetlov/peps","owner":{"login":"asvetlov","id":356399,"avatar_url":"https://avatars.githubusercontent.com/u/356399?v=3","gravatar_id":"","url":"https://api.github.com/users/asvetlov","html_url":"https://github.com/asvetlov","followers_url":"https://api.github.com/users/asvetlov/followers","following_url":"https://api.github.com/users/asvetlov/following{/other_user}","gists_url":"https://api.github.com/users/asvetlov/gists{/gist_id}","starred_url":"https://api.github.com/users/asvetlov/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/asvetlov/subscriptions","organizations_url":"https://api.github.com/users/asvetlov/orgs","repos_url":"https://api.github.com/users/asvetlov/repos","events_url":"https://api.github.com/users/asvetlov/events{/privacy}","received_events_url":"https://api.github.com/users/asvetlov/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/asvetlov/peps","description":"Python Enhancement Proposals","fork":true,"url":"https://api.github.com/repos/asvetlov/peps","forks_url":"https://api.github.com/repos/asvetlov/peps/forks","keys_url":"https://api.github.com/repos/asvetlov/peps/keys{/key_id}","collaborators_url":"https://api.github.com/repos/asvetlov/peps/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/asvetlov/peps/teams","hooks_url":"https://api.github.com/repos/asvetlov/peps/hooks","issue_events_url":"https://api.github.com/repos/asvetlov/peps/issues/events{/number}","events_url":"https://api.github.com/repos/asvetlov/peps/events","assignees_url":"https://api.github.com/repos/asvetlov/peps/assignees{/user}","branches_url":"https://api.github.com/repos/asvetlov/peps/branches{/branch}","tags_url":"https://api.github.com/repos/asvetlov/peps/tags","blobs_url":"https://api.github.com/repos/asvetlov/peps/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/asvetlov/peps/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/asvetlov/peps/git/refs{/sha}","trees_url":"https://api.github.com/repos/asvetlov/peps/git/trees{/sha}","statuses_url":"https://api.github.com/repos/asvetlov/peps/statuses/{sha}","languages_url":"https://api.github.com/repos/asvetlov/peps/languages","stargazers_url":"https://api.github.com/repos/asvetlov/peps/stargazers","contributors_url":"https://api.github.com/repos/asvetlov/peps/contributors","subscribers_url":"https://api.github.com/repos/asvetlov/peps/subscribers","subscription_url":"https://api.github.com/repos/asvetlov/peps/subscription","commits_url":"https://api.github.com/repos/asvetlov/peps/commits{/sha}","git_commits_url":"https://api.github.com/repos/asvetlov/peps/git/commits{/sha}","comments_url":"https://api.github.com/repos/asvetlov/peps/comments{/number}","issue_comment_url":"https://api.github.com/repos/asvetlov/peps/issues/comments{/number}","contents_url":"https://api.github.com/repos/asvetlov/peps/contents/{+path}","compare_url":"https://api.github.com/repos/asvetlov/peps/compare/{base}...{head}","merges_url":"https://api.github.com/repos/asvetlov/peps/merges","archive_url":"https://api.github.com/repos/asvetlov/peps/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/asvetlov/peps/downloads","issues_url":"https://api.github.com/repos/asvetlov/peps/issues{/number}","pulls_url":"https://api.github.com/repos/asvetlov/peps/pulls{/number}","milestones_url":"https://api.github.com/repos/asvetlov/peps/milestones{/number}","notifications_url":"https://api.github.com/repos/asvetlov/peps/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/asvetlov/peps/labels{/name}","releases_url":"https://api.github.com/repos/asvetlov/peps/releases{/id}","deployments_url":"https://api.github.com/repos/asvetlov/peps/deployments","created_at":"2016-09-19T15:07:03Z","updated_at":"2016-09-19T15:07:06Z","pushed_at":"2016-09-19T16:25:44Z","git_url":"git://github.com/asvetlov/peps.git","ssh_url":"git@github.com:asvetlov/peps.git","clone_url":"https://github.com/asvetlov/peps.git","svn_url":"https://github.com/asvetlov/peps","homepage":"https://www.python.org/dev/peps/","size":7719,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_downloads":true,"has_wiki":false,"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":"python:master","ref":"master","sha":"a116d3d13c9b15c15c9fb5323ac0f419d68cfda3","user":{"login":"python","id":1525981,"avatar_url":"https://avatars.githubusercontent.com/u/1525981?v=3","gravatar_id":"","url":"https://api.github.com/users/python","html_url":"https://github.com/python","followers_url":"https://api.github.com/users/python/followers","following_url":"https://api.github.com/users/python/following{/other_user}","gists_url":"https://api.github.com/users/python/gists{/gist_id}","starred_url":"https://api.github.com/users/python/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/python/subscriptions","organizations_url":"https://api.github.com/users/python/orgs","repos_url":"https://api.github.com/users/python/repos","events_url":"https://api.github.com/users/python/events{/privacy}","received_events_url":"https://api.github.com/users/python/received_events","type":"Organization","site_admin":false},"repo":{"id":13414105,"name":"peps","full_name":"python/peps","owner":{"login":"python","id":1525981,"avatar_url":"https://avatars.githubusercontent.com/u/1525981?v=3","gravatar_id":"","url":"https://api.github.com/users/python","html_url":"https://github.com/python","followers_url":"https://api.github.com/users/python/followers","following_url":"https://api.github.com/users/python/following{/other_user}","gists_url":"https://api.github.com/users/python/gists{/gist_id}","starred_url":"https://api.github.com/users/python/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/python/subscriptions","organizations_url":"https://api.github.com/users/python/orgs","repos_url":"https://api.github.com/users/python/repos","events_url":"https://api.github.com/users/python/events{/privacy}","received_events_url":"https://api.github.com/users/python/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/python/peps","description":"Python Enhancement Proposals","fork":false,"url":"https://api.github.com/repos/python/peps","forks_url":"https://api.github.com/repos/python/peps/forks","keys_url":"https://api.github.com/repos/python/peps/keys{/key_id}","collaborators_url":"https://api.github.com/repos/python/peps/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/python/peps/teams","hooks_url":"https://api.github.com/repos/python/peps/hooks","issue_events_url":"https://api.github.com/repos/python/peps/issues/events{/number}","events_url":"https://api.github.com/repos/python/peps/events","assignees_url":"https://api.github.com/repos/python/peps/assignees{/user}","branches_url":"https://api.github.com/repos/python/peps/branches{/branch}","tags_url":"https://api.github.com/repos/python/peps/tags","blobs_url":"https://api.github.com/repos/python/peps/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/python/peps/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/python/peps/git/refs{/sha}","trees_url":"https://api.github.com/repos/python/peps/git/trees{/sha}","statuses_url":"https://api.github.com/repos/python/peps/statuses/{sha}","languages_url":"https://api.github.com/repos/python/peps/languages","stargazers_url":"https://api.github.com/repos/python/peps/stargazers","contributors_url":"https://api.github.com/repos/python/peps/contributors","subscribers_url":"https://api.github.com/repos/python/peps/subscribers","subscription_url":"https://api.github.com/repos/python/peps/subscription","commits_url":"https://api.github.com/repos/python/peps/commits{/sha}","git_commits_url":"https://api.github.com/repos/python/peps/git/commits{/sha}","comments_url":"https://api.github.com/repos/python/peps/comments{/number}","issue_comment_url":"https://api.github.com/repos/python/peps/issues/comments{/number}","contents_url":"https://api.github.com/repos/python/peps/contents/{+path}","compare_url":"https://api.github.com/repos/python/peps/compare/{base}...{head}","merges_url":"https://api.github.com/repos/python/peps/merges","archive_url":"https://api.github.com/repos/python/peps/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/python/peps/downloads","issues_url":"https://api.github.com/repos/python/peps/issues{/number}","pulls_url":"https://api.github.com/repos/python/peps/pulls{/number}","milestones_url":"https://api.github.com/repos/python/peps/milestones{/number}","notifications_url":"https://api.github.com/repos/python/peps/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/python/peps/labels{/name}","releases_url":"https://api.github.com/repos/python/peps/releases{/id}","deployments_url":"https://api.github.com/repos/python/peps/deployments","created_at":"2013-10-08T13:27:12Z","updated_at":"2016-09-20T09:59:43Z","pushed_at":"2016-09-21T02:27:00Z","git_url":"git://github.com/python/peps.git","ssh_url":"git@github.com:python/peps.git","clone_url":"https://github.com/python/peps.git","svn_url":"https://github.com/python/peps","homepage":"https://www.python.org/dev/peps/","size":7912,"stargazers_count":198,"watchers_count":198,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":false,"has_pages":false,"forks_count":57,"mirror_url":null,"open_issues_count":11,"forks":57,"open_issues":11,"watchers":198,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/python/peps/pulls/105"},"html":{"href":"https://github.com/python/peps/pull/105"},"issue":{"href":"https://api.github.com/repos/python/peps/issues/105"},"comments":{"href":"https://api.github.com/repos/python/peps/issues/105/comments"},"review_comments":{"href":"https://api.github.com/repos/python/peps/pulls/105/comments"},"review_comment":{"href":"https://api.github.com/repos/python/peps/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/python/peps/pulls/105/commits"},"statuses":{"href":"https://api.github.com/repos/python/peps/statuses/82396eae3b78831664d7acf7e34faa34a0467d95"}}}}
{"actor":{"display_login":"asvetlov"}}