Jump to content

Logging and handlers

- - - - -

  • Please log in to reply
No replies to this topic

#1
denarced

denarced

    Programmer

  • Members
  • PipPipPipPip
  • 182 posts
Hei,

I've been having a problematic situation where I think that my logger-object received several handlers (identical) which in turn leads to getting clone lines in my log file. My primary delegator-class gets the same logger (same name) on each instantiation and creates the same file handler (same parameters) for it, but the problem is that when python-nose runs several tests, something remains because of those clone lines appear in the logfile.

What I wanna know now is either how to solve it or how to get around it (could be one and the same).
One solution is to check whether that logger already has a handler, I just can't find out how and I've been through python logging-documentation.

Any and all help appreciated :)




1 user(s) are reading this topic

0 members, 1 guests, 0 anonymous users