]> git.ipfire.org Git - thirdparty/Python/cpython.git/commitdiff
[3.14] gh-137985: Correct description of Formatter's datefmt param in logging documen...
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Tue, 16 Sep 2025 13:55:29 +0000 (15:55 +0200)
committerGitHub <noreply@github.com>
Tue, 16 Sep 2025 13:55:29 +0000 (16:55 +0300)
Co-authored-by: W. H. Wang <mattwang44@gmail.com>
Doc/library/logging.rst

index 79d8673a7e764b98e21a1ecc9a06085697fcd119..dd92e73b88ec2e679e8830b45db64aff0c66835f 100644 (file)
@@ -671,8 +671,7 @@ Formatter Objects
        which is just the logged message.
    :type fmt: str
 
-   :param datefmt: A format string in the given *style* for
-       the date/time portion of the logged output.
+   :param datefmt: A format string for the date/time portion of the logged output.
        If not specified, the default described in :meth:`formatTime` is used.
    :type datefmt: str
 
@@ -680,7 +679,7 @@ Formatter Objects
        how the format string will be merged with its data: using one of
        :ref:`old-string-formatting` (``%``), :meth:`str.format` (``{``)
        or :class:`string.Template` (``$``). This only applies to
-       *fmt* and *datefmt* (e.g. ``'%(message)s'`` versus ``'{message}'``),
+       *fmt* (e.g. ``'%(message)s'`` versus ``'{message}'``),
        not to the actual log messages passed to the logging methods.
        However, there are :ref:`other ways <formatting-styles>`
        to use ``{``- and ``$``-formatting for log messages.