[Python-Dev] Using logging in the stdlib and its unit tests
v+python at g.nevcal.com
Sat Dec 11 10:44:33 CET 2010
On 12/11/2010 1:07 AM, Nick Coghlan wrote:
> As Glenn mentioned later in the thread, the output of logging.info and
> logging.debug messages is*distinct* from an application's normal
> operational output that is emitted on stdout. So making it easy to
> emit such messages on stderr is the right thing to do - it's OK that
> it requires a bit of additional set up to get them onto stdout instead
> (since they really don't belong there most of the time).
> I know my own rule of thumb is going to be updated along the lines of
> "Am I writing to sys.stderr, or guarding output with a verbosity flag?
> Then perhaps I should be using the logging module rather than print
I'm in agreement with all this. Thanks for the correction.
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the Python-Dev