logger module

This module contains a logger, which monitors stdout and stderr and stores the information written to it into a temporary file. The Logger uses should be used with python’s with statement. You can write:

from pyvhist.logger import Logger
from pyvhist.tempdir import TempDir

logfile = "output.log"
with Logger(logfile, tempDir) as log:
    doStuff()

addFileToVhistSection(log.filename)

You can use the property filename after your code left the with-block to access the filename of the temporary file, which contains the log output.

class pyvhist.logger.Logger(filename, tempDir)

A class, which monitors stdout and stderr

__init__(filename, tempDir)

Previous topic

stopwatch module

Next topic

zipsource module

This Page