]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
Revert "[3.8] [doc] Fix erroneous backslashes in signatures and names (GH-23658)...
authorJulien Palard <julien@palard.fr>
Mon, 4 Jan 2021 16:19:16 +0000 (17:19 +0100)
committerGitHub <noreply@github.com>
Mon, 4 Jan 2021 16:19:16 +0000 (17:19 +0100)
This partially reverts commit
02349e2dc9d93202c658ae383b2de2e36b2366f8, which was removing
backslashes in documentations compiled with Sphinx < 3, used for
Python 3.8 and 3.9 docs.

Doc/library/asyncio-stream.rst
Doc/library/base64.rst
Doc/library/difflib.rst
Doc/library/email.header.rst
Doc/library/functions.rst
Doc/library/http.cookies.rst
Doc/library/io.rst
Doc/library/xml.dom.minidom.rst
Doc/requirements.txt

index 584bf10fc042bc2de0be9e326261e2eb279e4c41..714de8d41a3503cfde0c4131d9983c32932f7e5c 100644 (file)
@@ -192,7 +192,7 @@ StreamReader
       can be read.  Use the :attr:`IncompleteReadError.partial`
       attribute to get the partially read data.
 
-   .. coroutinemethod:: readuntil(separator=b'\n')
+   .. coroutinemethod:: readuntil(separator=b'\\n')
 
       Read data from the stream until *separator* is found.
 
index 3c63c15ad401e9fad35d94c1efaca9438e491f31..ad9f5f58bee2aac1f330f612519809b01dbb5a64 100644 (file)
@@ -178,7 +178,7 @@ The modern interface provides:
    .. versionadded:: 3.4
 
 
-.. function:: a85decode(b, *, foldspaces=False, adobe=False, ignorechars=b' \t\n\r\v')
+.. function:: a85decode(b, *, foldspaces=False, adobe=False, ignorechars=b' \\t\\n\\r\\v')
 
    Decode the Ascii85 encoded :term:`bytes-like object` or ASCII string *b* and
    return the decoded :class:`bytes`.
index e6dd1dd7a54f0345ddda072bea3a0ccce4298b44..a8543b38c197ec70ef3dff219e64542fce39be36 100644 (file)
@@ -149,7 +149,7 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module.
    contains a good example of its use.
 
 
-.. function:: context_diff(a, b, fromfile='', tofile='', fromfiledate='', tofiledate='', n=3, lineterm='\n')
+.. function:: context_diff(a, b, fromfile='', tofile='', fromfiledate='', tofiledate='', n=3, lineterm='\\n')
 
    Compare *a* and *b* (lists of strings); return a delta (a :term:`generator`
    generating the delta lines) in context diff format.
@@ -279,7 +279,7 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module.
       emu
 
 
-.. function:: unified_diff(a, b, fromfile='', tofile='', fromfiledate='', tofiledate='', n=3, lineterm='\n')
+.. function:: unified_diff(a, b, fromfile='', tofile='', fromfiledate='', tofiledate='', n=3, lineterm='\\n')
 
    Compare *a* and *b* (lists of strings); return a delta (a :term:`generator`
    generating the delta lines) in unified diff format.
@@ -321,7 +321,7 @@ diffs. For comparing directories and files, see also, the :mod:`filecmp` module.
 
    See :ref:`difflib-interface` for a more detailed example.
 
-.. function:: diff_bytes(dfunc, a, b, fromfile=b'', tofile=b'', fromfiledate=b'', tofiledate=b'', n=3, lineterm=b'\n')
+.. function:: diff_bytes(dfunc, a, b, fromfile=b'', tofile=b'', fromfiledate=b'', tofiledate=b'', n=3, lineterm=b'\\n')
 
    Compare *a* and *b* (lists of bytes objects) using *dfunc*; yield a
    sequence of delta lines (also bytes) in the format returned by *dfunc*.
index e093f138936b3631f8fc49f152d9ed8b9e5f658a..07152c224f2ff0865aee9561757733f69c5e2d80 100644 (file)
@@ -116,7 +116,7 @@ Here is the :class:`Header` class description:
       if *s* is a byte string.
 
 
-   .. method:: encode(splitchars=';, \t', maxlinelen=None, linesep='\n')
+   .. method:: encode(splitchars=';, \\t', maxlinelen=None, linesep='\\n')
 
       Encode a message header into an RFC-compliant format, possibly wrapping
       long lines and encapsulating non-ASCII parts in base64 or quoted-printable
index be98d30488ab8a5d94aa3081ea6ce4f739245adb..4f5fe6bc23069777f76021c85e1eb0a5e5b73db6 100644 (file)
@@ -1312,7 +1312,7 @@ are always available.  They are listed here in alphabetical order.
       supported.
 
 
-.. function:: print(*objects, sep=' ', end='\n', file=sys.stdout, flush=False)
+.. function:: print(*objects, sep=' ', end='\\n', file=sys.stdout, flush=False)
 
    Print *objects* to the text stream *file*, separated by *sep* and followed
    by *end*.  *sep*, *end*, *file* and *flush*, if present, must be given as keyword
index a2c1eb00d8b33db0c3a9309c828a053456fb4fe4..17792b200599bd8b9e048f3803e05f423cc78b32 100644 (file)
@@ -93,7 +93,7 @@ Cookie Objects
    :meth:`value_decode` are inverses on the range of *value_decode*.
 
 
-.. method:: BaseCookie.output(attrs=None, header='Set-Cookie:', sep='\r\n')
+.. method:: BaseCookie.output(attrs=None, header='Set-Cookie:', sep='\\r\\n')
 
    Return a string representation suitable to be sent as HTTP headers. *attrs* and
    *header* are sent to each :class:`Morsel`'s :meth:`output` method. *sep* is used
index 667e4c654ff2356485e77ee2c97caf5c478dfd2d..32151a0ace458e2b4647942e6d0a02d513ae0a69 100644 (file)
@@ -959,7 +959,7 @@ Text I/O
       .. versionadded:: 3.7
 
 
-.. class:: StringIO(initial_value='', newline='\n')
+.. class:: StringIO(initial_value='', newline='\\n')
 
    An in-memory stream for text I/O.  The text buffer is discarded when the
    :meth:`~IOBase.close` method is called.
index 673af8326a80e375060e2a2ffca397ad90acbdd5..8711242d95d741c320668a4bbe3d26ba5eb6d0d3 100644 (file)
@@ -164,7 +164,7 @@ module documentation.  This section lists the differences between the API and
       The :meth:`toxml` method now preserves the attribute order specified
       by the user.
 
-.. method:: Node.toprettyxml(indent="\t", newl="\n", encoding=None)
+.. method:: Node.toprettyxml(indent="\\t", newl="\\n", encoding=None)
 
    Return a pretty-printed version of the document. *indent* specifies the
    indentation string and defaults to a tabulator; *newl* specifies the string
index d30ff39c8c9a3301ccb9fedb6af36f21de8cd569..47b78eeac817e010c759698cdafac7b1654fade7 100644 (file)
@@ -3,7 +3,7 @@
 # Sphinx version is pinned so that new versions that introduce new warnings
 # won't suddenly cause build failures. Updating the version is fine as long
 # as no warnings are raised by doing so.
-sphinx
+sphinx==2.4.4
 
 blurb