Branch: refs/heads/3.6 Home: https://github.com/python/cpython Commit: 3dc7c52a9f4fb83be3e26e31e2c7cd9dc1cb41a2 https://github.com/python/cpython/commit/3dc7c52a9f4fb83be3e26e31e2c7cd9dc1cb41a2 Author: INADA Naoki <methane at users.noreply.github.com> Date: 2017年05月11日 (2017年5月11日) Changed paths: M Lib/asyncio/tasks.py M Lib/test/test_asyncio/test_tasks.py M Misc/NEWS M Modules/_asynciomodule.c Log Message: ----------- bpo-30048: asyncio: fix Task.cancel() was ignored. (GH-1546) when there are no more `await` or `yield (from)` before return in coroutine, cancel was ignored. example: async def coro(): asyncio.Task.current_task().cancel() return 42 ... res = await coro() # should raise CancelledError (cherry picked from commit 991adca012f5e106c2d4040ce619c696ba6f9c46)