PyDocs

Nav

Generic Operating System Services

BaseRotatingHandler.rotate

logging.handlers

method of BaseRotatingHandler · Added in 3.3 (source)
  • BaseRotatingHandler.rotate(source, dest)
When rotating, rotate the current log.

The default implementation calls the 'rotator' attribute of the
handler, if it's callable, passing the source and dest arguments to
it. If the attribute isn't callable (the default is None), the source
is simply renamed to the destination.

:param source: The source filename. This is normally the base
               filename, e.g. 'test.log'
:param dest:   The destination filename. This is normally
               what the source is rotated to, e.g. 'test.log.1'.
0 Examples
No examples for logging.handlers/BaseRotatingHandler.rotate.
See Also
No see-alsos for logging.handlers/BaseRotatingHandler.rotate
0 Notes
No notes for BaseRotatingHandler.rotate