Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
805e27ef
Commit
805e27ef
authored
Sep 14, 2018
by
Yury Selivanov
Committed by
GitHub
Sep 14, 2018
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
bpo-33649: Fix asyncio-dev (GH-9324)
parent
afde1c1a
Changes
6
Expand all
Show whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
166 additions
and
339 deletions
+166
-339
Doc/library/asyncio-api-index.rst
Doc/library/asyncio-api-index.rst
+6
-6
Doc/library/asyncio-dev.rst
Doc/library/asyncio-dev.rst
+138
-316
Doc/library/asyncio-eventloop.rst
Doc/library/asyncio-eventloop.rst
+5
-0
Doc/library/asyncio-future.rst
Doc/library/asyncio-future.rst
+10
-4
Doc/library/asyncio.rst
Doc/library/asyncio.rst
+3
-10
Doc/library/ipc.rst
Doc/library/ipc.rst
+4
-3
No files found.
Doc/library/asyncio-api-index.rst
View file @
805e27ef
...
...
@@ -15,7 +15,7 @@ Utilities to run asyncio programs, create Tasks, and
await on multiple things with timeouts.
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - :func:`run`
- Create event loop, run a coroutine, close the loop.
...
...
@@ -71,7 +71,7 @@ implement connection pools, and pub/sub patterns.
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - :class:`Queue`
- A FIFO queue.
...
...
@@ -97,7 +97,7 @@ Subprocesses
Utilities to spawn subprocesses and run shell commands.
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - ``await`` :func:`create_subprocess_exec`
- Create a subprocess.
...
...
@@ -120,7 +120,7 @@ Streams
High-level APIs to work with network IO.
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - ``await`` :func:`open_connection`
- Establish a TCP connection.
...
...
@@ -155,7 +155,7 @@ Synchronization
Threading-like synchronization primitives that can be used in Tasks.
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - :class:`Lock`
- A mutex lock.
...
...
@@ -185,7 +185,7 @@ Exceptions
==========
.. list-table::
:widths:
30 7
0
:widths:
50 5
0
* - :exc:`asyncio.TimeoutError`
...
...
Doc/library/asyncio-dev.rst
View file @
805e27ef
This diff is collapsed.
Click to expand it.
Doc/library/asyncio-eventloop.rst
View file @
805e27ef
...
...
@@ -1075,6 +1075,11 @@ Enabling debug mode
Set the debug mode of the event loop.
.. versionchanged:: 3.7
The new ``-X dev`` command line option can now also be used
to enable the debug mode.
.. seealso::
The :ref:`debug mode of asyncio <asyncio-debug-mode>`.
...
...
Doc/library/asyncio-future.rst
View file @
805e27ef
...
...
@@ -121,6 +121,16 @@ Future Object
or an exception set with :meth:`set_result` or
:meth:`set_exception` calls.
.. method:: cancelled()
Return ``True`` if the Future was *cancelled*.
The method is usually used to check if a Future is not
*cancelled* before setting a result or an exception for it::
if not fut.cancelled():
fut.set_result(42)
.. method:: add_done_callback(callback, *, context=None)
Add a callback to be run when the Future is *done*.
...
...
@@ -180,10 +190,6 @@ Future Object
.. versionadded:: 3.7
.. method:: cancelled()
Return ``True`` if the Future was *cancelled*.
This example creates a Future object, creates and schedules an
asynchronous Task to set result for the Future, and waits until
...
...
Doc/library/asyncio.rst
View file @
805e27ef
...
...
@@ -32,8 +32,9 @@ asyncio provides a set of **high-level** APIs to:
as well as **low-level** APIs for *library and framework developers* to:
* create and manage :ref:`event loops <asyncio-event-loop>`, which
provide asynchronous APIs for networking, subprocesses, OS signals,
etc;
provide asynchronous APIs for :meth:`networking <loop.create_server>`,
running :meth:`subprocesses <loop.subprocess_exec>`,
handling :meth:`OS signals <loop.add_signal_handler>`, etc;
* implement efficient protocols using
:ref:`transports <asyncio-transports-protocols>`;
...
...
@@ -75,11 +76,3 @@ Reference
asyncio-api-index.rst
asyncio-dev.rst
.. seealso::
The :mod:`asyncio` module was proposed in :PEP:`3156`.
Since the acceptance of the PEP many new APIs were added and many
original APIs were altered. The PEP should be treated as a
historical document.
Doc/library/ipc.rst
View file @
805e27ef
.. _ipc:
*****************************************
Interprocess Communication and Networking
Networking and Interprocess Communication
*****************************************
The modules described in this chapter provide mechanisms for
different processes
to communicate
.
The modules described in this chapter provide mechanisms for
networking and inter-processes communication
.
Some modules only work for two processes that are on the same machine, e.g.
:mod:`signal` and :mod:`mmap`. Other modules support networking protocols
...
...
@@ -15,6 +15,7 @@ The list of modules described in this chapter is:
.. toctree::
:maxdepth: 1
asyncio.rst
socket.rst
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment