summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAndre Delfino <adelfino@gmail.com>2020-09-01 12:59:46 (GMT)
committerGitHub <noreply@github.com>2020-09-01 12:59:46 (GMT)
commitf5a16b4dbf62cb9b48c42098bd5a8cfa665456c3 (patch)
tree94e895a9a73a5d43273715554679cca44c5fc1d8
parenta4c4e17f959621ab00a98086af1704fb0c896466 (diff)
downloadcpython-f5a16b4dbf62cb9b48c42098bd5a8cfa665456c3.zip
cpython-f5a16b4dbf62cb9b48c42098bd5a8cfa665456c3.tar.gz
cpython-f5a16b4dbf62cb9b48c42098bd5a8cfa665456c3.tar.bz2
[doc] Add link to FileHandler in logging (GH-21940)
Co-authored-by: Andrés Delfino <adelfino@onapsis.com>
-rw-r--r--Doc/library/logging.rst31
1 files changed, 16 insertions, 15 deletions
diff --git a/Doc/library/logging.rst b/Doc/library/logging.rst
index a446c80..19691d5 100644
--- a/Doc/library/logging.rst
+++ b/Doc/library/logging.rst
@@ -1166,9 +1166,9 @@ functions.
+--------------+---------------------------------------------+
| Format | Description |
+==============+=============================================+
- | *filename* | Specifies that a FileHandler be created, |
- | | using the specified filename, rather than a |
- | | StreamHandler. |
+ | *filename* | Specifies that a :class:`FileHandler` be |
+ | | created, using the specified filename, |
+ | | rather than a :class:`StreamHandler`. |
+--------------+---------------------------------------------+
| *filemode* | If *filename* is specified, open the file |
| | in this :ref:`mode <filemodes>`. Defaults |
@@ -1192,9 +1192,10 @@ functions.
| | :ref:`level <levels>`. |
+--------------+---------------------------------------------+
| *stream* | Use the specified stream to initialize the |
- | | StreamHandler. Note that this argument is |
- | | incompatible with *filename* - if both |
- | | are present, a ``ValueError`` is raised. |
+ | | :class:`StreamHandler`. Note that this |
+ | | argument is incompatible with *filename* - |
+ | | if both are present, a ``ValueError`` is |
+ | | raised. |
+--------------+---------------------------------------------+
| *handlers* | If specified, this should be an iterable of |
| | already created handlers to add to the root |
@@ -1213,18 +1214,18 @@ functions.
+--------------+---------------------------------------------+
| *encoding* | If this keyword argument is specified along |
| | with *filename*, its value is used when the |
- | | FileHandler is created, and thus used when |
- | | opening the output file. |
+ | | :class:`FileHandler` is created, and thus |
+ | | used when opening the output file. |
+--------------+---------------------------------------------+
| *errors* | If this keyword argument is specified along |
| | with *filename*, its value is used when the |
- | | FileHandler is created, and thus used when |
- | | opening the output file. If not specified, |
- | | the value 'backslashreplace' is used. Note |
- | | that if ``None`` is specified, it will be |
- | | passed as such to :func:`open`, which means |
- | | that it will be treated the same as passing |
- | | 'errors'. |
+ | | :class:`FileHandler` is created, and thus |
+ | | used when opening the output file. If not |
+ | | specified, the value 'backslashreplace' is |
+ | | used. Note that if ``None`` is specified, |
+ | | it will be passed as such to :func:`open`, |
+ | | which means that it will be treated the |
+ | | same as passing 'errors'. |
+--------------+---------------------------------------------+
.. versionchanged:: 3.2