summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorYury Selivanov <yury@magic.io>2018-05-28 21:54:02 (GMT)
committerGitHub <noreply@github.com>2018-05-28 21:54:02 (GMT)
commit416c1ebd9896b394790dcb4f9f035b1a44ebe9ff (patch)
treea5003eed8be41259a0e545fde1c2d22bf2ac23c7 /Modules
parentfdccfe09f0b10776645fdb04a0783d6864c32b21 (diff)
downloadcpython-416c1ebd9896b394790dcb4f9f035b1a44ebe9ff.zip
cpython-416c1ebd9896b394790dcb4f9f035b1a44ebe9ff.tar.gz
cpython-416c1ebd9896b394790dcb4f9f035b1a44ebe9ff.tar.bz2
bpo-32610: Fix asyncio.all_tasks() to return only pending tasks. (GH-7174)
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_asynciomodule.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/Modules/_asynciomodule.c b/Modules/_asynciomodule.c
index c4d1903..e3537cc 100644
--- a/Modules/_asynciomodule.c
+++ b/Modules/_asynciomodule.c
@@ -11,7 +11,7 @@ module _asyncio
/* identifiers used from some functions */
_Py_IDENTIFIER(__asyncio_running_event_loop__);
_Py_IDENTIFIER(add_done_callback);
-_Py_IDENTIFIER(all_tasks);
+_Py_IDENTIFIER(_all_tasks_compat);
_Py_IDENTIFIER(call_soon);
_Py_IDENTIFIER(cancel);
_Py_IDENTIFIER(current_task);
@@ -2125,7 +2125,7 @@ _asyncio_Task_all_tasks_impl(PyTypeObject *type, PyObject *loop)
return NULL;
}
- all_tasks_func = _PyObject_GetAttrId(asyncio_mod, &PyId_all_tasks);
+ all_tasks_func = _PyObject_GetAttrId(asyncio_mod, &PyId__all_tasks_compat);
if (all_tasks_func == NULL) {
return NULL;
}