[Python-checkins] cpython (merge 3.4 -> default): Issue #22251: Fix ReST markup to avoid errors building docs.

berker.peksag python-checkins at python.org
Sat Sep 27 22:22:28 CEST 2014


https://hg.python.org/cpython/rev/ed1dbac90b92
changeset:   92609:ed1dbac90b92
parent:      92606:8a56d87b81ef
parent:      92608:0ec56e677bc3
user:        Berker Peksag <berker.peksag at gmail.com>
date:        Sat Sep 27 23:22:35 2014 +0300
summary:
  Issue #22251: Fix ReST markup to avoid errors building docs.

files:
  Doc/extending/newtypes.rst           |  2 ++
  Doc/faq/library.rst                  |  4 +++-
  Doc/library/argparse.rst             |  1 +
  Doc/library/asyncio-eventloop.rst    |  4 +++-
  Doc/library/asyncio-protocol.rst     |  2 ++
  Doc/library/asyncio-task.rst         |  1 +
  Doc/library/email.contentmanager.rst |  4 +++-
  Doc/library/logging.handlers.rst     |  4 +++-
  Doc/library/multiprocessing.rst      |  1 +
  Doc/library/os.rst                   |  1 +
  Doc/library/pathlib.rst              |  3 +++
  Doc/library/pickle.rst               |  1 +
  Doc/library/ssl.rst                  |  3 +++
  Doc/library/statistics.rst           |  4 +++-
  Doc/library/stdtypes.rst             |  1 +
  Doc/library/sys.rst                  |  1 +
  Doc/library/warnings.rst             |  1 +
  Doc/using/cmdline.rst                |  6 +++++-
  18 files changed, 38 insertions(+), 6 deletions(-)


diff --git a/Doc/extending/newtypes.rst b/Doc/extending/newtypes.rst
--- a/Doc/extending/newtypes.rst
+++ b/Doc/extending/newtypes.rst
@@ -983,6 +983,7 @@
    }
 
 .. note::
+
    There are limitations to what you can safely do in a deallocator function.
    First, if your type supports garbage collection (using :c:member:`~PyTypeObject.tp_traverse`
    and/or :c:member:`~PyTypeObject.tp_clear`), some of the object's members can have been
@@ -997,6 +998,7 @@
    :c:member:`~PyTypeObject.tp_finalize` type method.
 
    .. seealso::
+
       :pep:`442` explains the new finalization scheme.
 
 .. index::
diff --git a/Doc/faq/library.rst b/Doc/faq/library.rst
--- a/Doc/faq/library.rst
+++ b/Doc/faq/library.rst
@@ -697,7 +697,9 @@
    >>> urllib.parse.urlencode({'name': 'Guy Steele, Jr.'})
    'name=Guy+Steele%2C+Jr.'
 
-.. seealso:: :ref:`urllib-howto` for extensive examples.
+.. seealso::
+
+   :ref:`urllib-howto` for extensive examples.
 
 
 What module should I use to help with generating HTML?
diff --git a/Doc/library/argparse.rst b/Doc/library/argparse.rst
--- a/Doc/library/argparse.rst
+++ b/Doc/library/argparse.rst
@@ -1894,6 +1894,7 @@
    (Namespace(bar='BAR', foo=True), ['--badger', 'spam'])
 
 .. warning::
+
    :ref:`Prefix matching <prefix-matching>` rules apply to
    :meth:`parse_known_args`. The parser may consume an option even if it's just
    a prefix of one of its known options, instead of leaving it in the remaining
diff --git a/Doc/library/asyncio-eventloop.rst b/Doc/library/asyncio-eventloop.rst
--- a/Doc/library/asyncio-eventloop.rst
+++ b/Doc/library/asyncio-eventloop.rst
@@ -197,7 +197,9 @@
      the transport; if *ssl* is :const:`True`, a context with some
      unspecified default settings is used.
 
-     .. seealso:: :ref:`SSL/TLS security considerations <ssl-security>`
+     .. seealso::
+
+        :ref:`SSL/TLS security considerations <ssl-security>`
 
    * *server_hostname*, is only for use together with *ssl*,
      and sets or overrides the hostname that the target server's certificate
diff --git a/Doc/library/asyncio-protocol.rst b/Doc/library/asyncio-protocol.rst
--- a/Doc/library/asyncio-protocol.rst
+++ b/Doc/library/asyncio-protocol.rst
@@ -407,6 +407,7 @@
 buffer size reaches the low-water mark.
 
 .. note::
+
    If the buffer size equals the high-water mark,
    :meth:`pause_writing` is not called -- it must go strictly over.
    Conversely, :meth:`resume_writing` is called when the buffer size is
@@ -415,6 +416,7 @@
    mark is zero.
 
 .. note::
+
    On BSD systems (OS X, FreeBSD, etc.) flow control is not supported
    for :class:`DatagramProtocol`, because send failures caused by
    writing too many packets cannot be detected easily.  The socket
diff --git a/Doc/library/asyncio-task.rst b/Doc/library/asyncio-task.rst
--- a/Doc/library/asyncio-task.rst
+++ b/Doc/library/asyncio-task.rst
@@ -269,6 +269,7 @@
 the future.
 
 .. note::
+
    The :meth:`~BaseEventLoop.run_until_complete` method uses internally the
    :meth:`~Future.add_done_callback` method to be notified when the future is
    done.
diff --git a/Doc/library/email.contentmanager.rst b/Doc/library/email.contentmanager.rst
--- a/Doc/library/email.contentmanager.rst
+++ b/Doc/library/email.contentmanager.rst
@@ -405,7 +405,9 @@
        ``message/rfc822``, use ``8bit`` if *cte* is not specified.  For all
        other values of *subtype*, use ``7bit``.
 
-       .. note:: A *cte* of ``binary`` does not actually work correctly yet.
+       .. note::
+
+          A *cte* of ``binary`` does not actually work correctly yet.
           The ``Message`` object as modified by ``set_content`` is correct, but
           :class:`~email.generator.BytesGenerator` does not serialize it
           correctly.
diff --git a/Doc/library/logging.handlers.rst b/Doc/library/logging.handlers.rst
--- a/Doc/library/logging.handlers.rst
+++ b/Doc/library/logging.handlers.rst
@@ -864,7 +864,9 @@
       :meth:`mapLogRecord` method is used to convert the record to the
       dictionary to be sent.
 
-   .. note:: Since preparing a record for sending it to a Web server is not
+   .. note::
+
+      Since preparing a record for sending it to a Web server is not
       the same as a generic formatting operation, using
       :meth:`~logging.Handler.setFormatter` to specify a
       :class:`~logging.Formatter` for a :class:`HTTPHandler` has no effect.
diff --git a/Doc/library/multiprocessing.rst b/Doc/library/multiprocessing.rst
--- a/Doc/library/multiprocessing.rst
+++ b/Doc/library/multiprocessing.rst
@@ -851,6 +851,7 @@
    :exc:`NotImplementedError`.
 
    .. seealso::
+
       :func:`os.cpu_count`
 
 .. function:: current_process()
diff --git a/Doc/library/os.rst b/Doc/library/os.rst
--- a/Doc/library/os.rst
+++ b/Doc/library/os.rst
@@ -57,6 +57,7 @@
    ``'ce'``, ``'java'``.
 
    .. seealso::
+
       :attr:`sys.platform` has a finer granularity.  :func:`os.uname` gives
       system-dependent version information.
 
diff --git a/Doc/library/pathlib.rst b/Doc/library/pathlib.rst
--- a/Doc/library/pathlib.rst
+++ b/Doc/library/pathlib.rst
@@ -32,15 +32,18 @@
    useful since those simply don't have any OS-accessing operations.
 
 .. note::
+
    This module has been included in the standard library on a
    :term:`provisional basis <provisional package>`. Backwards incompatible
    changes (up to and including removal of the package) may occur if deemed
    necessary by the core developers.
 
 .. seealso::
+
    :pep:`428`: The pathlib module -- object-oriented filesystem paths.
 
 .. seealso::
+
    For low-level path manipulation on strings, you can also use the
    :mod:`os.path` module.
 
diff --git a/Doc/library/pickle.rst b/Doc/library/pickle.rst
--- a/Doc/library/pickle.rst
+++ b/Doc/library/pickle.rst
@@ -141,6 +141,7 @@
   brought by protocol 4.
 
 .. note::
+
    Serialization is a more primitive notion than persistence; although
    :mod:`pickle` reads and writes file objects, it does not handle the issue of
    naming persistent objects, nor the (even more complicated) issue of concurrent
diff --git a/Doc/library/ssl.rst b/Doc/library/ssl.rst
--- a/Doc/library/ssl.rst
+++ b/Doc/library/ssl.rst
@@ -259,6 +259,7 @@
    default CA certificates.
 
    .. note::
+
       The protocol, options, cipher and other settings may change to more
       restrictive values anytime without prior deprecation.  The values
       represent a fair balance between compatibility and security.
@@ -267,6 +268,7 @@
       :class:`SSLContext` and apply the settings yourself.
 
    .. note::
+
       If you find that when certain older clients or servers attempt to connect
       with a :class:`SSLContext` created by this function that they get an
       error stating "Protocol or cipher suite mismatch", it may be that they
@@ -963,6 +965,7 @@
    interoperability.
 
    .. seealso::
+
       :func:`create_default_context` lets the :mod:`ssl` module choose
       security settings for a given purpose.
 
diff --git a/Doc/library/statistics.rst b/Doc/library/statistics.rst
--- a/Doc/library/statistics.rst
+++ b/Doc/library/statistics.rst
@@ -135,7 +135,9 @@
    This is suited for when your data is discrete, and you don't mind that the
    median may not be an actual data point.
 
-   .. seealso:: :func:`median_low`, :func:`median_high`, :func:`median_grouped`
+   .. seealso::
+
+      :func:`median_low`, :func:`median_high`, :func:`median_grouped`
 
 
 .. function:: median_low(data)
diff --git a/Doc/library/stdtypes.rst b/Doc/library/stdtypes.rst
--- a/Doc/library/stdtypes.rst
+++ b/Doc/library/stdtypes.rst
@@ -3872,6 +3872,7 @@
       :ref:`documentation of view objects <dict-views>`.
 
 .. seealso::
+
    :class:`types.MappingProxyType` can be used to create a read-only view
    of a :class:`dict`.
 
diff --git a/Doc/library/sys.rst b/Doc/library/sys.rst
--- a/Doc/library/sys.rst
+++ b/Doc/library/sys.rst
@@ -798,6 +798,7 @@
 
 
    .. seealso::
+
       Module :mod:`site` This describes how to use .pth files to extend
       :data:`sys.path`.
 
diff --git a/Doc/library/warnings.rst b/Doc/library/warnings.rst
--- a/Doc/library/warnings.rst
+++ b/Doc/library/warnings.rst
@@ -41,6 +41,7 @@
 custom implementations.
 
 .. seealso::
+
    :func:`logging.captureWarnings` allows you to handle all warnings with
    the standard logging infrastructure.
 
diff --git a/Doc/using/cmdline.rst b/Doc/using/cmdline.rst
--- a/Doc/using/cmdline.rst
+++ b/Doc/using/cmdline.rst
@@ -107,6 +107,7 @@
        python -mtimeit -h # for details
 
    .. seealso::
+
       :func:`runpy.run_module`
          Equivalent functionality directly available to Python code
 
@@ -158,7 +159,9 @@
 .. versionchanged:: 3.4
    Automatic enabling of tab-completion and history editing.
 
-.. seealso::  :ref:`tut-invoking`
+.. seealso::
+
+   :ref:`tut-invoking`
 
 
 Generic options
@@ -362,6 +365,7 @@
    thus equivalent to an omitted line number.
 
    .. seealso::
+
       :mod:`warnings` -- the warnings module
 
       :pep:`230` -- Warning framework

-- 
Repository URL: https://hg.python.org/cpython


More information about the Python-checkins mailing list