[Python-checkins] cpython (merge 3.4 -> default): Merge with 3.4
zach.ware
python-checkins at python.org
Tue Jan 6 07:47:36 CET 2015
https://hg.python.org/cpython/rev/8120043810af
changeset: 94040:8120043810af
parent: 94038:141f6a3c4153
parent: 94039:37801e3b82e4
user: Zachary Ware <zachary.ware at gmail.com>
date: Tue Jan 06 00:45:52 2015 -0600
summary:
Merge with 3.4
files:
Doc/library/asyncio-dev.rst | 18 ++++++++++--------
1 files changed, 10 insertions(+), 8 deletions(-)
diff --git a/Doc/library/asyncio-dev.rst b/Doc/library/asyncio-dev.rst
--- a/Doc/library/asyncio-dev.rst
+++ b/Doc/library/asyncio-dev.rst
@@ -71,8 +71,8 @@
.. seealso::
- See the :ref:`Synchronization primitives <asyncio-sync>` section to
- synchronize tasks.
+ The :ref:`Synchronization primitives <asyncio-sync>` section describes ways
+ to synchronize tasks.
.. _asyncio-handle-blocking:
@@ -112,8 +112,8 @@
----------------------------------------
When a coroutine function is called and its result is not passed to
-:func:`async` or to the :meth:`BaseEventLoop.create_task` method: the execution
-of the coroutine objet will never be scheduled and it is probably a bug.
+:func:`async` or to the :meth:`BaseEventLoop.create_task` method, the execution
+of the coroutine object will never be scheduled which is probably a bug.
:ref:`Enable the debug mode of asyncio <asyncio-debug-mode>` to :ref:`log a
warning <asyncio-logger>` to detect it.
@@ -147,7 +147,7 @@
Python usually calls :func:`sys.displayhook` on unhandled exceptions. If
:meth:`Future.set_exception` is called, but the exception is never consumed,
-:func:`sys.displayhook` is not called. Instead, a :ref:`a log is emitted
+:func:`sys.displayhook` is not called. Instead, :ref:`a log is emitted
<asyncio-logger>` when the future is deleted by the garbage collector, with the
traceback where the exception was raised.
@@ -195,7 +195,7 @@
raise Exception("not consumed")
Exception: not consumed
-There are different options to fix this issue. The first option is to chain to
+There are different options to fix this issue. The first option is to chain the
coroutine in another coroutine and use classic try/except::
@asyncio.coroutine
@@ -218,10 +218,12 @@
except Exception:
print("exception consumed")
-See also the :meth:`Future.exception` method.
+.. seealso::
+ The :meth:`Future.exception` method.
-Chain correctly coroutines
+
+Chain coroutines correctly
--------------------------
When a coroutine function calls other coroutine functions and tasks, they
--
Repository URL: https://hg.python.org/cpython
More information about the Python-checkins
mailing list