Commit 9dd10412 authored by Éric Araujo's avatar Éric Araujo

Fix note markup (#16805).

Patch by Tshepang Lekhonkhobe, reviewed by Georg Brandl.
parent d33a32f1
...@@ -534,6 +534,7 @@ code, or when embedding the Python interpreter: ...@@ -534,6 +534,7 @@ code, or when embedding the Python interpreter:
.. index:: module: thread .. index:: module: thread
.. note:: .. note::
When only the main thread exists, no GIL operations are needed. This is a When only the main thread exists, no GIL operations are needed. This is a
common situation (most Python programs do not use threads), and the lock common situation (most Python programs do not use threads), and the lock
operations slow the interpreter down a bit. Therefore, the lock is not operations slow the interpreter down a bit. Therefore, the lock is not
......
...@@ -10,6 +10,7 @@ ...@@ -10,6 +10,7 @@
-------------- --------------
.. note:: .. note::
The :mod:`getopt` module is a parser for command line options whose API is The :mod:`getopt` module is a parser for command line options whose API is
designed to be familiar to users of the C :c:func:`getopt` function. Users who designed to be familiar to users of the C :c:func:`getopt` function. Users who
are unfamiliar with the C :c:func:`getopt` function or who would like to write are unfamiliar with the C :c:func:`getopt` function or who would like to write
......
...@@ -644,6 +644,7 @@ than raw I/O does. ...@@ -644,6 +644,7 @@ than raw I/O does.
:exc:`UnsupportedOperation`. :exc:`UnsupportedOperation`.
.. warning:: .. warning::
:class:`BufferedRWPair` does not attempt to synchronize accesses to :class:`BufferedRWPair` does not attempt to synchronize accesses to
its underlying raw streams. You should not pass it the same object its underlying raw streams. You should not pass it the same object
as reader and writer; use :class:`BufferedRandom` instead. as reader and writer; use :class:`BufferedRandom` instead.
......
...@@ -118,7 +118,9 @@ in :mod:`logging` itself) and defining handlers which are declared either in ...@@ -118,7 +118,9 @@ in :mod:`logging` itself) and defining handlers which are declared either in
send it to the socket as a string of bytes preceded by a four-byte length send it to the socket as a string of bytes preceded by a four-byte length
string packed in binary using ``struct.pack('>L', n)``. string packed in binary using ``struct.pack('>L', n)``.
.. note:: Because portions of the configuration are passed through .. note::
Because portions of the configuration are passed through
:func:`eval`, use of this function may open its users to a security risk. :func:`eval`, use of this function may open its users to a security risk.
While the function only binds to a socket on ``localhost``, and so does While the function only binds to a socket on ``localhost``, and so does
not accept connections from remote machines, there are scenarios where not accept connections from remote machines, there are scenarios where
...@@ -721,7 +723,9 @@ The ``class`` entry is optional. It indicates the name of the formatter's class ...@@ -721,7 +723,9 @@ The ``class`` entry is optional. It indicates the name of the formatter's class
:class:`~logging.Formatter` can present exception tracebacks in an expanded or :class:`~logging.Formatter` can present exception tracebacks in an expanded or
condensed format. condensed format.
.. note:: Due to the use of :func:`eval` as described above, there are .. note::
Due to the use of :func:`eval` as described above, there are
potential security risks which result from using the :func:`listen` to send potential security risks which result from using the :func:`listen` to send
and receive configurations via sockets. The risks are limited to where and receive configurations via sockets. The risks are limited to where
multiple users with no mutual trust run code on the same machine; see the multiple users with no mutual trust run code on the same machine; see the
......
...@@ -157,7 +157,9 @@ process and user. ...@@ -157,7 +157,9 @@ process and user.
Availability: Unix. Availability: Unix.
.. note:: On Mac OS X, :func:`getgroups` behavior differs somewhat from .. note::
On Mac OS X, :func:`getgroups` behavior differs somewhat from
other Unix platforms. If the Python interpreter was built with a other Unix platforms. If the Python interpreter was built with a
deployment target of :const:`10.5` or earlier, :func:`getgroups` returns deployment target of :const:`10.5` or earlier, :func:`getgroups` returns
the list of effective group ids associated with the current user process; the list of effective group ids associated with the current user process;
......
...@@ -562,6 +562,7 @@ correspond to Unix system calls applicable to sockets. ...@@ -562,6 +562,7 @@ correspond to Unix system calls applicable to sockets.
automatically closed when they are garbage-collected. automatically closed when they are garbage-collected.
.. note:: .. note::
:meth:`close()` releases the resource associated with a connection but :meth:`close()` releases the resource associated with a connection but
does not necessarily close the connection immediately. If you want does not necessarily close the connection immediately. If you want
to close the connection in a timely fashion, call :meth:`shutdown()` to close the connection in a timely fashion, call :meth:`shutdown()`
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment