title: Do you have to reinstantiate the logging logger to have it perform file cleanup?
body: <p>I'm working with the code in question: <a href="https://stackoverflow.com/questions/40088496/how-to-use-pythons-rotatingfilehandler">How to use Python&#39;s RotatingFileHandler</a></p>
  
  <p>Specifically this bit...</p>
  
  <pre><code>import logging
  from logging.handlers import RotatingFileHandler
  
  logger = logging.getLogger('my_logger')
  logger.setLevel(logging.DEBUG)
  handler = RotatingFileHandler('my_log.log', maxBytes=2000, backupCount=10)
  logger.addHandler(handler)
  
  for _ in range(10000):
      logger.debug('Hello, world!')
  </code></pre>
  
  <p>I put this at the beginning of my code, but my requirements dictate that I have to build this into a daemon, so the code at the core of the application will run forever.</p>
  
  <p>Do I have to reinstantiate the logger for log cleanup to occur, or is the check made every time a log is written?</p>