Append, don't truncate, log file

The new logging handler was truncating the log file on each start.
Append by default.

Signed-off-by: Sebastian Spaeth <Sebastian@SSpaeth.de>
This commit is contained in:
Sebastian Spaeth 2011-11-02 10:56:42 +01:00
parent 54117e702d
commit 4eeb88dd8f

View File

@ -81,7 +81,7 @@ class UIBase(object):
def setlogfile(self, logfile):
"""Create file handler which logs to file"""
fh = logging.FileHandler(logfile, 'wt')
fh = logging.FileHandler(logfile, 'at')
#fh.setLevel(logging.DEBUG)
file_formatter = logging.Formatter("%(asctime)s %(levelname)s: "
"%(message)s", '%Y-%m-%d %H:%M:%S')