Jason Tackaberry wrote:
> Right now there's a logger for notifier, but what's the best practice
> for logging in general?  Should each module allocate its own logger and
> use that?  Should there be one logger for kaa and all kaa modules use
> that logger?  I'm leaning toward the latter simply because that way it
> only requires attaching a handler to one logger rather than an arbitrary
> number.  But I'm not sure what's best practice.

Freevo uses different logger (and kaa, too). The good stuff is you can
set different debug levels. E.g. there is something from with the ipc
code, set the ipc logger to logging.DEBUG and the notifier logger will
still be on default level. Only when you add stuff to the default
logger, it will affect all loggers without config.

Summary: different loggers please.

Which reminds me: you added adding a logger in step if no logger is
defined. Can you remove that and add a kaa.log() function to start the
logging. Sometimes I have the need for a logger before step/loop and
it makes no sense (even if it is fast) to check this in each
iteraton. 


Dischi

-- 
I am a friend of the working man, and I would rather be his friend
than be one.
                -- Clarence Darrow

Attachment: pgpCRJk5dCBJb.pgp
Description: PGP signature

Reply via email to