Skip to content

Commit 8ac4830

Browse files
authored
Docs fixups following implement socket factory (#10534) (#10568)
1 parent 4599b87 commit 8ac4830

File tree

4 files changed

+12
-14
lines changed

4 files changed

+12
-14
lines changed

CHANGES/10474.feature.rst

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
10520.feature.rst

docs/client_advanced.rst

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -472,8 +472,8 @@ Custom socket creation
472472
^^^^^^^^^^^^^^^^^^^^^^
473473

474474
If the default socket is insufficient for your use case, pass an optional
475-
`socket_factory` to the :class:`~aiohttp.TCPConnector`, which implements
476-
`SocketFactoryType`. This will be used to create all sockets for the
475+
``socket_factory`` to the :class:`~aiohttp.TCPConnector`, which implements
476+
:class:`SocketFactoryType`. This will be used to create all sockets for the
477477
lifetime of the class object. For example, we may want to change the
478478
conditions under which we consider a connection dead. The following would
479479
make all sockets respect 9*7200 = 18 hours::

docs/client_reference.rst

Lines changed: 7 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1122,31 +1122,27 @@ is controlled by *force_close* constructor's parameter).
11221122
overridden in subclasses.
11231123

11241124

1125-
.. autodata:: AddrInfoType
1126-
1127-
.. note::
1125+
.. py:class:: AddrInfoType
11281126
11291127
Refer to :py:data:`aiohappyeyeballs.AddrInfoType` for more info.
11301128

11311129
.. warning::
11321130

11331131
Be sure to use ``aiohttp.AddrInfoType`` rather than
11341132
``aiohappyeyeballs.AddrInfoType`` to avoid import breakage, as
1135-
it is likely to be removed from ``aiohappyeyeballs`` in the
1133+
it is likely to be removed from :mod:`aiohappyeyeballs` in the
11361134
future.
11371135

11381136

1139-
.. autodata:: SocketFactoryType
1140-
1141-
.. note::
1137+
.. py:class:: SocketFactoryType
11421138
11431139
Refer to :py:data:`aiohappyeyeballs.SocketFactoryType` for more info.
11441140

11451141
.. warning::
11461142

11471143
Be sure to use ``aiohttp.SocketFactoryType`` rather than
11481144
``aiohappyeyeballs.SocketFactoryType`` to avoid import breakage,
1149-
as it is likely to be removed from ``aiohappyeyeballs`` in the
1145+
as it is likely to be removed from :mod:`aiohappyeyeballs` in the
11501146
future.
11511147

11521148

@@ -1278,9 +1274,9 @@ is controlled by *force_close* constructor's parameter).
12781274

12791275
.. versionadded:: 3.10
12801276

1281-
:param :py:data:``SocketFactoryType`` socket_factory: This function takes an
1282-
:py:data:``AddrInfoType`` and is used in lieu of ``socket.socket()`` when
1283-
creating TCP connections.
1277+
:param SocketFactoryType socket_factory: This function takes an
1278+
:py:data:`AddrInfoType` and is used in lieu of
1279+
:py:func:`socket.socket` when creating TCP connections.
12841280

12851281
.. versionadded:: 3.12
12861282

docs/conf.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -83,7 +83,7 @@
8383
"aiohttpsession": ("https://aiohttp-session.readthedocs.io/en/stable/", None),
8484
"aiohttpdemos": ("https://aiohttp-demos.readthedocs.io/en/latest/", None),
8585
"aiojobs": ("https://aiojobs.readthedocs.io/en/stable/", None),
86-
"aiohappyeyeballs": ("https://aiohappyeyeballs.readthedocs.io/en/stable/", None),
86+
"aiohappyeyeballs": ("https://aiohappyeyeballs.readthedocs.io/en/latest/", None),
8787
}
8888

8989
# Add any paths that contain templates here, relative to this directory.
@@ -419,6 +419,7 @@
419419
("py:class", "aiohttp.web.MatchedSubAppResource"), # undocumented
420420
("py:attr", "body"), # undocumented
421421
("py:class", "socket.socket"), # undocumented
422+
("py:func", "socket.socket"), # undocumented
422423
("py:class", "socket.AddressFamily"), # undocumented
423424
("py:obj", "logging.DEBUG"), # undocumented
424425
("py:class", "aiohttp.abc.AbstractAsyncAccessLogger"), # undocumented

0 commit comments

Comments
 (0)