Skip to content

[3.11] gh-101100: Fix sphinx warnings in library/asyncio-eventloop.rst (GH-111222) #111470

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Oct 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 8 additions & 6 deletions Doc/library/asyncio-eventloop.rst
Original file line number Diff line number Diff line change
Expand Up @@ -495,7 +495,7 @@ Opening network connections

.. versionchanged:: 3.6

The socket option :py:const:`~socket.TCP_NODELAY` is set by default
The socket option :ref:`socket.TCP_NODELAY <socket-unix-constants>` is set by default
for all TCP connections.

.. versionchanged:: 3.7
Expand Down Expand Up @@ -564,7 +564,7 @@ Opening network connections
* *reuse_port* tells the kernel to allow this endpoint to be bound to the
same port as other existing endpoints are bound to, so long as they all
set this flag when being created. This option is not supported on Windows
and some Unixes. If the :py:const:`~socket.SO_REUSEPORT` constant is not
and some Unixes. If the :ref:`socket.SO_REUSEPORT <socket-unix-constants>` constant is not
defined then this capability is unsupported.

* *allow_broadcast* tells the kernel to allow this endpoint to send
Expand All @@ -590,7 +590,8 @@ Opening network connections

.. versionchanged:: 3.8.1
The *reuse_address* parameter is no longer supported, as using
:py:const:`~sockets.SO_REUSEADDR` poses a significant security concern for
:ref:`socket.SO_REUSEADDR <socket-unix-constants>`
poses a significant security concern for
UDP. Explicitly passing ``reuse_address=True`` will raise an exception.

When multiple processes with differing UIDs assign sockets to an
Expand All @@ -599,7 +600,8 @@ Opening network connections

For supported platforms, *reuse_port* can be used as a replacement for
similar functionality. With *reuse_port*,
:py:const:`~sockets.SO_REUSEPORT` is used instead, which specifically
:ref:`socket.SO_REUSEPORT <socket-unix-constants>`
is used instead, which specifically
prevents processes with differing UIDs from assigning sockets to the same
socket address.

Expand Down Expand Up @@ -741,7 +743,7 @@ Creating network servers
.. versionchanged:: 3.6

Added *ssl_handshake_timeout* and *start_serving* parameters.
The socket option :py:const:`~socket.TCP_NODELAY` is set by default
The socket option :ref:`socket.TCP_NODELAY <socket-unix-constants>` is set by default
for all TCP connections.

.. versionchanged:: 3.11
Expand Down Expand Up @@ -1853,7 +1855,7 @@ Set signal handlers for SIGINT and SIGTERM

(This ``signals`` example only works on Unix.)

Register handlers for signals :py:data:`SIGINT` and :py:data:`SIGTERM`
Register handlers for signals :const:`~signal.SIGINT` and :const:`~signal.SIGTERM`
using the :meth:`loop.add_signal_handler` method::

import asyncio
Expand Down
7 changes: 7 additions & 0 deletions Doc/library/socket.rst
Original file line number Diff line number Diff line change
Expand Up @@ -326,6 +326,11 @@ Constants
defined then this protocol is unsupported. More constants may be available
depending on the system.

.. data:: AF_UNSPEC

:const:`AF_UNSPEC` means that
:func:`getaddrinfo` should return socket addresses for any
address family (either IPv4, IPv6, or any other) that can be used.

.. data:: SOCK_STREAM
SOCK_DGRAM
Expand Down Expand Up @@ -354,6 +359,8 @@ Constants

.. versionadded:: 3.2

.. _socket-unix-constants:

.. data:: SO_*
SOMAXCONN
MSG_*
Expand Down
1 change: 0 additions & 1 deletion Doc/tools/.nitignore
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@ Doc/howto/urllib2.rst
Doc/library/__future__.rst
Doc/library/abc.rst
Doc/library/ast.rst
Doc/library/asyncio-eventloop.rst
Doc/library/asyncio-extending.rst
Doc/library/asyncio-policy.rst
Doc/library/asyncio-stream.rst
Expand Down