
This issue trackerhas been migrated toGitHub, and is currentlyread-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.
Created on2019-11-13 08:34 byakayunov, last changed2022-04-11 14:59 byadmin. This issue is nowclosed.
| Files | ||||
|---|---|---|---|---|
| File name | Uploaded | Description | Edit | |
| scratch_15.py | akayunov,2019-11-13 08:34 | |||
| Pull Requests | |||
|---|---|---|---|
| URL | Status | Linked | Edit |
| PR 17144 | merged | asvetlov,2019-11-13 14:20 | |
| PR 17147 | merged | miss-islington,2019-11-13 21:37 | |
| PR 17148 | merged | miss-islington,2019-11-13 21:37 | |
| Messages (8) | |||
|---|---|---|---|
| msg356523 -(view) | Author: Alex (akayunov) | Date: 2019-11-13 08:34 | |
Get Segmentation fault on run script in attachment. | |||
| msg356524 -(view) | Author: Alex (akayunov) | Date: 2019-11-13 08:47 | |
Get seg fault on running script in attachment:root@fake:/opt/securisync/be# python3.7 scratch_15.pyIn tratata beforeIn tratata2 beforeSegmentation fault | |||
| msg356526 -(view) | Author: Andrew Svetlov (asvetlov)*![]() | Date: 2019-11-13 10:20 | |
Thanks for the report!I would say that deriving from the future class without calling super().__init__() is an error.After fixing this the snippet raises expected "RuntimeError: yield was used instead of yield from in task" error. | |||
| msg356527 -(view) | Author: STINNER Victor (vstinner)*![]() | Date: 2019-11-13 10:36 | |
The crash occurs in _asyncio_Future_get_loop():(gdb) frame#0 0x00007fffea2fe689 in _Py_INCREF (op=0x0) at ./Include/object.h:459459 op->ob_refcnt++;(gdb) up#1 0x00007fffea301b14 in _asyncio_Future_get_loop_impl (self=0x7fffea2615f0) at /home/vstinner/python/master/Modules/_asynciomodule.c:10941094 Py_INCREF(self->fut_loop);(gdb) p self->fut_loop$1 = 0x0(gdb) where#0 0x00007fffea2fe689 in _Py_INCREF (op=0x0) at ./Include/object.h:459#1 0x00007fffea301b14 in _asyncio_Future_get_loop_impl (self=0x7fffea2615f0) at /home/vstinner/python/master/Modules/_asynciomodule.c:1094#2 0x00007fffea2fef01 in _asyncio_Future_get_loop (self=0x7fffea2615f0, _unused_ignored=0x0) at /home/vstinner/python/master/Modules/clinic/_asynciomodule.c.h:252#3 0x0000000000645364 in cfunction_vectorcall_NOARGS ( func=<built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0>, args=0x0, nargsf=0, kwnames=0x0) atObjects/methodobject.c:424#4 0x000000000042f8d1 in _PyObject_VectorcallTstate (tstate=0x81ae00, callable=<built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0>, args=0x0, nargsf=0, kwnames=0x0) at ./Include/cpython/abstract.h:111#5 0x000000000042f930 in _PyObject_Vectorcall ( callable=<built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0>, args=0x0, nargsf=0, kwnames=0x0) at ./Include/cpython/abstract.h:120#6 0x000000000042f988 in _PyObject_CallNoArg ( func=<built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0>) at ./Include/cpython/abstract.h:148#7 0x000000000042fc57 in PyObject_CallNoArgs ( func=<built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0>) atObjects/call.c:83#8 0x00007fffea2ffc16 in get_future_loop ( fut=<Qwe2(value=0) at remote 0x7fffea2615f0>)--Type <RET> for more, q to quit, c to continue without paging--qQuit(gdb) py-btTraceback (most recent call first): <built-in method get_loop of Qwe2 object at remote 0x7fffea2615f0> <built-in method run of Context object at remote 0x7fffea215170> File "/home/vstinner/python/master/Lib/asyncio/events.py", line 81, in _run self._context.run(self._callback, *self._args) File "/home/vstinner/python/master/Lib/asyncio/base_events.py", line 2641, in _run_once File "/home/vstinner/python/master/Lib/asyncio/base_events.py", line 1101, in run_forever await waiter File "/home/vstinner/python/master/Lib/asyncio/base_events.py", line 621, in run_until_complete self.run_forever() File "/home/vstinner/python/master/Lib/asyncio/runners.py", line 299, in run File "/home/vstinner/python/master/scratch_15.py", line 56, in <module> asyncio.run(main()) | |||
| msg356528 -(view) | Author: Andrew Svetlov (asvetlov)*![]() | Date: 2019-11-13 10:44 | |
Looks like get_future_loop() function misses ENSURE_FUTURE_ALIVE macro call. | |||
| msg356557 -(view) | Author: miss-islington (miss-islington) | Date: 2019-11-13 21:37 | |
New changesetdad6be5ffe48beb74fad78cf758b886afddc7aed by Miss Islington (bot) (Andrew Svetlov) in branch 'master':bpo-38785: Prevent asyncio from crashing (GH-17144)https://github.com/python/cpython/commit/dad6be5ffe48beb74fad78cf758b886afddc7aed | |||
| msg356559 -(view) | Author: miss-islington (miss-islington) | Date: 2019-11-13 21:54 | |
New changeset87b4d3994e4f81d6e39a5e86c1b7040df065ea37 by Miss Islington (bot) in branch '3.7':bpo-38785: Prevent asyncio from crashing (GH-17144)https://github.com/python/cpython/commit/87b4d3994e4f81d6e39a5e86c1b7040df065ea37 | |||
| msg356560 -(view) | Author: miss-islington (miss-islington) | Date: 2019-11-13 21:54 | |
New changeset694c03fabb5cf3df0102cc317670a10fc39c6786 by Miss Islington (bot) in branch '3.8':bpo-38785: Prevent asyncio from crashing (GH-17144)https://github.com/python/cpython/commit/694c03fabb5cf3df0102cc317670a10fc39c6786 | |||
| History | |||
|---|---|---|---|
| Date | User | Action | Args |
| 2022-04-11 14:59:23 | admin | set | github: 82966 |
| 2019-11-13 21:55:19 | asvetlov | set | status: open -> closed stage: patch review -> resolved resolution: fixed versions: + Python 3.8, Python 3.9 |
| 2019-11-13 21:54:59 | miss-islington | set | messages: +msg356560 |
| 2019-11-13 21:54:58 | miss-islington | set | messages: +msg356559 |
| 2019-11-13 21:37:23 | miss-islington | set | pull_requests: +pull_request16657 |
| 2019-11-13 21:37:16 | miss-islington | set | pull_requests: +pull_request16656 |
| 2019-11-13 21:37:15 | miss-islington | set | nosy: +miss-islington messages: +msg356557 |
| 2019-11-13 14:20:49 | asvetlov | set | keywords: +patch stage: patch review pull_requests: +pull_request16654 |
| 2019-11-13 10:44:31 | asvetlov | set | messages: +msg356528 |
| 2019-11-13 10:36:54 | vstinner | set | nosy: +vstinner messages: +msg356527 |
| 2019-11-13 10:20:52 | asvetlov | set | messages: +msg356526 |
| 2019-11-13 08:47:31 | akayunov | set | messages: +msg356524 |
| 2019-11-13 08:34:09 | akayunov | create | |