File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -831,6 +831,13 @@ should have the desired effect. If an organisation produces a number of
831831libraries, then the logger name specified can be 'orgname.foo' rather than
832832just 'foo'.
833833
834+ .. note :: It is strongly advised that you *do not log to the root logger*
835+ in your library. Instead, use a logger with a unique and easily
836+ identifiable name, such as the ``__name__ `` for your library's top-level package
837+ or module. Logging to the root logger will make it difficult or impossible for
838+ the application developer to configure the logging verbosity or handlers of
839+ your library as they wish.
840+
834841.. note :: It is strongly advised that you *do not add any handlers other
835842 than* :class: `~logging.NullHandler ` *to your library's loggers *. This is
836843 because the configuration of handlers is the prerogative of the application
You can’t perform that action at this time.
0 commit comments