Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit f0c7436

Browse filesBrowse files
geryogamvsajip
authored andcommitted
bpo-35722: Updated the documentation for the 'disable_existing_loggers' parameter (GH-11525)
1 parent da6424e commit f0c7436
Copy full SHA for f0c7436

File tree

Expand file treeCollapse file tree

2 files changed

+10
-10
lines changed
Filter options
Expand file treeCollapse file tree

2 files changed

+10
-10
lines changed

‎Doc/howto/logging.rst

Copy file name to clipboardExpand all lines: Doc/howto/logging.rst
+5-5Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -695,15 +695,15 @@ noncoders to easily modify the logging properties.
695695
.. warning:: The :func:`fileConfig` function takes a default parameter,
696696
``disable_existing_loggers``, which defaults to ``True`` for reasons of
697697
backward compatibility. This may or may not be what you want, since it
698-
will cause any loggers existing before the :func:`fileConfig` call to
699-
be disabled unless they (or an ancestor) are explicitly named in the
700-
configuration. Please refer to the reference documentation for more
698+
will cause any non-root loggers existing before the :func:`fileConfig`
699+
call to be disabled unless they (or an ancestor) are explicitly named in
700+
the configuration. Please refer to the reference documentation for more
701701
information, and specify ``False`` for this parameter if you wish.
702702

703703
The dictionary passed to :func:`dictConfig` can also specify a Boolean
704704
value with key ``disable_existing_loggers``, which if not specified
705705
explicitly in the dictionary also defaults to being interpreted as
706-
``True``. This leads to the logger-disabling behaviour described above,
706+
``True``. This leads to the logger-disabling behaviour described above,
707707
which may not be what you want - in which case, provide the key
708708
explicitly with a value of ``False``.
709709

@@ -802,7 +802,7 @@ the best default behaviour.
802802
If for some reason you *don't* want these messages printed in the absence of
803803
any logging configuration, you can attach a do-nothing handler to the top-level
804804
logger for your library. This avoids the message being printed, since a handler
805-
will be always be found for the library's events: it just doesn't produce any
805+
will always be found for the library's events: it just doesn't produce any
806806
output. If the library user configures logging for application use, presumably
807807
that configuration will add some handlers, and if levels are suitably
808808
configured then logging calls made in library code will send output to those

‎Doc/library/logging.config.rst

Copy file name to clipboardExpand all lines: Doc/library/logging.config.rst
+5-5Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -107,9 +107,9 @@ in :mod:`logging` itself) and defining handlers which are declared either in
107107
enabled. The default is ``True`` because this
108108
enables old behaviour in a
109109
backward-compatible way. This behaviour is to
110-
disable any existing loggers unless they or
111-
their ancestors are explicitly named in the
112-
logging configuration.
110+
disable any existing non-root loggers unless
111+
they or their ancestors are explicitly named
112+
in the logging configuration.
113113

114114
.. versionchanged:: 3.4
115115
An instance of a subclass of :class:`~configparser.RawConfigParser` is
@@ -313,8 +313,8 @@ otherwise, the context is used to determine what to instantiate.
313313
If the specified value is ``True``, the configuration is processed
314314
as described in the section on :ref:`logging-config-dict-incremental`.
315315

316-
* *disable_existing_loggers* - whether any existing loggers are to be
317-
disabled. This setting mirrors the parameter of the same name in
316+
* *disable_existing_loggers* - whether any existing non-root loggers are
317+
to be disabled. This setting mirrors the parameter of the same name in
318318
:func:`fileConfig`. If absent, this parameter defaults to ``True``.
319319
This value is ignored if *incremental* is ``True``.
320320

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.