Open log files with UTF-8 encoding.

It seems to work better that way, at least on Python 3.
This commit is contained in:
Valentin Lorentz 2016-03-24 22:04:35 +01:00
parent 3879f30d47
commit 92ed5d484d
1 changed files with 1 additions and 1 deletions

View File

@ -193,7 +193,7 @@ if not os.path.exists(pluginLogDir):
try:
messagesLogFilename = os.path.join(_logDir, 'messages.log')
_handler = BetterFileHandler(messagesLogFilename)
_handler = BetterFileHandler(messagesLogFilename, encoding='utf8')
except EnvironmentError as e:
raise SystemExit('Error opening messages logfile (%s). ' \
'Generally, this is because you are running Supybot in a directory ' \