@@ -397,11 +397,11 @@ Opening network connections
397397 Open a streaming transport connection to a given
398398 address specified by *host * and *port *.
399399
400- The socket family can be either :py:data : `~socket.AF_INET ` or
401- :py:data : `~socket.AF_INET6 ` depending on *host * (or the *family *
400+ The socket family can be either :py:const : `~socket.AF_INET ` or
401+ :py:const : `~socket.AF_INET6 ` depending on *host * (or the *family *
402402 argument, if provided).
403403
404- The socket type will be :py:data : `~socket.SOCK_STREAM `.
404+ The socket type will be :py:const : `~socket.SOCK_STREAM `.
405405
406406 *protocol_factory * must be a callable returning an
407407 :ref: `asyncio protocol <asyncio-protocol >` implementation.
@@ -495,7 +495,7 @@ Opening network connections
495495
496496 .. versionchanged :: 3.6
497497
498- The socket option :py:data : `~socket.TCP_NODELAY ` is set by default
498+ The socket option :py:const : `~socket.TCP_NODELAY ` is set by default
499499 for all TCP connections.
500500
501501 .. versionchanged :: 3.7
@@ -535,11 +535,11 @@ Opening network connections
535535
536536 Create a datagram connection.
537537
538- The socket family can be either :py:data : `~socket.AF_INET `,
539- :py:data : `~socket.AF_INET6 `, or :py:data : `~socket.AF_UNIX `,
538+ The socket family can be either :py:const : `~socket.AF_INET `,
539+ :py:const : `~socket.AF_INET6 `, or :py:const : `~socket.AF_UNIX `,
540540 depending on *host * (or the *family * argument, if provided).
541541
542- The socket type will be :py:data : `~socket.SOCK_DGRAM `.
542+ The socket type will be :py:const : `~socket.SOCK_DGRAM `.
543543
544544 *protocol_factory * must be a callable returning a
545545 :ref: `protocol <asyncio-protocol >` implementation.
@@ -564,7 +564,7 @@ Opening network connections
564564 * *reuse_port * tells the kernel to allow this endpoint to be bound to the
565565 same port as other existing endpoints are bound to, so long as they all
566566 set this flag when being created. This option is not supported on Windows
567- and some Unixes. If the :py:data : `~socket.SO_REUSEPORT ` constant is not
567+ and some Unixes. If the :py:const : `~socket.SO_REUSEPORT ` constant is not
568568 defined then this capability is unsupported.
569569
570570 * *allow_broadcast * tells the kernel to allow this endpoint to send
@@ -590,7 +590,7 @@ Opening network connections
590590
591591 .. versionchanged :: 3.8.1
592592 The *reuse_address * parameter is no longer supported, as using
593- :py:data : `~sockets.SO_REUSEADDR ` poses a significant security concern for
593+ :py:const : `~sockets.SO_REUSEADDR ` poses a significant security concern for
594594 UDP. Explicitly passing ``reuse_address=True `` will raise an exception.
595595
596596 When multiple processes with differing UIDs assign sockets to an
@@ -599,7 +599,7 @@ Opening network connections
599599
600600 For supported platforms, *reuse_port * can be used as a replacement for
601601 similar functionality. With *reuse_port *,
602- :py:data : `~sockets.SO_REUSEPORT ` is used instead, which specifically
602+ :py:const : `~sockets.SO_REUSEPORT ` is used instead, which specifically
603603 prevents processes with differing UIDs from assigning sockets to the same
604604 socket address.
605605
@@ -617,8 +617,8 @@ Opening network connections
617617
618618 Create a Unix connection.
619619
620- The socket family will be :py:data : `~socket.AF_UNIX `; socket
621- type will be :py:data : `~socket.SOCK_STREAM `.
620+ The socket family will be :py:const : `~socket.AF_UNIX `; socket
621+ type will be :py:const : `~socket.SOCK_STREAM `.
622622
623623 A tuple of ``(transport, protocol) `` is returned on success.
624624
@@ -654,7 +654,7 @@ Creating network servers
654654 ssl_shutdown_timeout=None, \
655655 start_serving=True)
656656
657- Create a TCP server (socket type :data : `~socket.SOCK_STREAM `) listening
657+ Create a TCP server (socket type :const : `~socket.SOCK_STREAM `) listening
658658 on *port * of the *host * address.
659659
660660 Returns a :class: `Server ` object.
@@ -682,10 +682,10 @@ Creating network servers
682682 be selected (note that if *host * resolves to multiple network interfaces,
683683 a different random port will be selected for each interface).
684684
685- * *family * can be set to either :data : `socket.AF_INET ` or
686- :data : `~socket.AF_INET6 ` to force the socket to use IPv4 or IPv6.
685+ * *family * can be set to either :const : `socket.AF_INET ` or
686+ :const : `~socket.AF_INET6 ` to force the socket to use IPv4 or IPv6.
687687 If not set, the *family * will be determined from host name
688- (defaults to :data : `~socket.AF_UNSPEC `).
688+ (defaults to :const : `~socket.AF_UNSPEC `).
689689
690690 * *flags * is a bitmask for :meth: `getaddrinfo `.
691691
@@ -739,7 +739,7 @@ Creating network servers
739739 .. versionchanged :: 3.6
740740
741741 Added *ssl_handshake_timeout * and *start_serving * parameters.
742- The socket option :py:data : `~socket.TCP_NODELAY ` is set by default
742+ The socket option :py:const : `~socket.TCP_NODELAY ` is set by default
743743 for all TCP connections.
744744
745745 .. versionchanged :: 3.11
@@ -760,7 +760,7 @@ Creating network servers
760760 start_serving=True)
761761
762762 Similar to :meth: `loop.create_server ` but works with the
763- :py:data : `~socket.AF_UNIX ` socket family.
763+ :py:const : `~socket.AF_UNIX ` socket family.
764764
765765 *path * is the name of a Unix domain socket, and is required,
766766 unless a *sock * argument is provided. Abstract Unix sockets,
0 commit comments