title: Managing loggers with Python logging
body: <p>I'm writing a server app which should be able to log at different levels both on the console and a log file.</p>
  
  <p>The problem is, if logging.basicConfig() is set it will log to the console but it must be set in the main thread.</p>
  
  <p>It can also be set with logging.basicConfig(filename='logger.log') to write to a file.</p>
  
  <p>Setting a handle either for console logging (logging.StreamHandler()) or file logging (logging.FileHandler()) complements the logging.baseconfig() option set.</p>
  
  <p>The problem is, that the settings are not independent.
  What I mean is, the loglevel of logging.baseConfig() must include the Handler level, or it wont be logged.</p>
  
  <p>So if I set the baseConfig to log to file, and a StreamHandler to log to console, the file loglevel must be lower than the console level.
  (Also, the basicConfig option logs all other logs.)</p>
  
  <p>I tried to create two Handles, one for the console and one for the log file, they work, but whatever log type is specified by basicConfig() will still be displayed duplicating messages.</p>
  
  <p>Is there a way to disable the output of basicConfig() ?
  Or any other way to implement these options ?</p>
  
  <p>Thanks.</p>