Yury Selivanov
176f2ebdad
bpo-30508: Don't log exceptions if Task/Future "cancel()" method was called. ( #2109 )
2017-06-11 14:00:14 +00:00
INADA Naoki
3dc7c52a9f
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 991adca012
)
2017-05-11 21:56:42 +09:00
Yury Selivanov
d8b72e4a06
bpo-28963: Fix out of bound iteration in asyncio.Future.remove_done_callback/C ( #408 )
2017-03-03 00:05:22 -05:00
Yury Selivanov
13802a3b11
bpo-29271: Fix Task.current_task and Task.all_tasks to accept None. ( #406 )
2017-03-02 23:19:49 -05:00
Victor Stinner
cb2128cada
_asyncio uses _PyObject_CallMethodIdObjArgs()
...
Issue #28920 : Replace _PyObject_CallMethodId(obj, meth, "O", arg) with
_PyObject_CallMethodIdObjArgs(obj, meth, arg, NULL) to avoid
_PyObject_CallMethodId() special case when arg is a tuple.
If arg is a tuple, _PyObject_CallMethodId() unpacks the tuple: obj.meth(*arg).
2016-12-15 09:05:11 +01:00
Yury Selivanov
c2c8fe1252
Issue #28843 : Fix asyncio C Task to handle exceptions __traceback__.
2016-12-01 11:36:22 -05:00
Benjamin Peterson
996fc1fcfc
correctly emulate error semantics of gen.throw in FutureIter_throw
2016-11-14 00:15:44 -08:00
Yury Selivanov
692796a948
Issue #26081 : Fix refleak in _asyncio.Future.__iter__().throw.
2016-11-08 19:04:57 -05:00
Serhiy Storchaka
60e49aa756
Issue #23996 : Added _PyGen_SetStopIterationValue for safe raising
...
StopIteration with value. More safely handle non-normalized exceptions
in -_PyGen_FetchStopIterationValue.
2016-11-06 18:47:03 +02:00
Victor Stinner
f94d1eee74
Issue #28544 : Fix inefficient call to _PyObject_CallMethodId()
...
"()" format string creates an empty list of argument but requires extra work to
parse the format string.
2016-10-29 09:05:39 +02:00
Yury Selivanov
684ef2c888
Issue #28544 : Pass `PyObject*` to _PyDict_Pop, not `PyDictObject*`
2016-10-28 19:01:21 -04:00
Victor Stinner
1aea8fb9e0
Issue #28544 : Fix _asynciomodule.c on Windows
...
PyType_Ready() sets the reference to &PyType_Type.
&PyType_Type cannot be resolved at compilation time (not on Windows?).
2016-10-28 19:13:52 +02:00
Yury Selivanov
a0c1ba608e
Issue #28544 : Implement asyncio.Task in C.
...
This implementation provides additional 10-20% speed boost for
asyncio programs.
The patch also fixes _asynciomodule.c to use Arguments Clinic, and
makes '_schedule_callbacks' an overridable method (as it was in 3.5).
2016-10-28 12:52:37 -04:00
INADA Naoki
74c17539f2
Issue #28430 : Fix iterator of C implemented asyncio.Future doesn't
...
accept non-None value is passed to it.send(val).
2016-10-25 19:00:45 +09:00
Yury Selivanov
53478f8c6d
Issue #28493 : Fix typos in _asynciomodule.c
...
Thanks to Stéphane Wirtel!
2016-10-20 16:33:19 -04:00
Yury Selivanov
a4b884f900
Issue #28492 : Fix how StopIteration is raised in _asyncio.Future
2016-10-20 15:54:20 -04:00
INADA Naoki
c411a7d821
Issue #28452 : Remove _asyncio._init_module function
2016-10-18 11:48:14 +09:00
INADA Naoki
9f2ce25481
Issue #28428 : Rename _futures module to _asyncio.
...
It will have more speedup functions or classes other than asyncio.Future.
2016-10-15 15:39:19 +09:00