How python logging get it's configuration
Posted
by
Andrew_1510
on Stack Overflow
See other posts from Stack Overflow
or by Andrew_1510
Published on 2012-04-04T06:34:02Z
Indexed on
2012/04/05
5:30 UTC
Read the original article
Hit count: 113
I used to Python logging, it works fine. The logging.basicConfig(...)
set in one module (a some.py
file), then we can use logging
every where. Obviously, logging is global.
The question is how logging find it's settings, when we not call the module
where basicConfig(...) appeared (in some.py file )? Is logging scan all the packages?
Even the logging.basicConfig(...)
put into an any.py
and the module (any.py
) never get imported, or not used anywhere, the logging setting take effect!
© Stack Overflow or respective owner