X-Git-Url: https://apps.delaporte.us/gitweb/matrix-chore-bot.git/blobdiff_plain/145745886f1614e292c17163884e15e669dcf224..23985ed419254cf2f06730a172c6a9df6ef97155:/matrix_chore_bot/bot.py diff --git a/matrix_chore_bot/bot.py b/matrix_chore_bot/bot.py index c1a76d3..2484c46 100644 --- a/matrix_chore_bot/bot.py +++ b/matrix_chore_bot/bot.py @@ -23,7 +23,6 @@ import simplematrixbotlib as botlib from .db import Data as ChoreData logger = logging.getLogger(__name__) -logging.basicConfig(filename='matrix-chore-bot.log', encoding='utf-8', level=logging.DEBUG) logging.getLogger('nio').setLevel(logging.WARNING) class ChoreBot(): @@ -33,6 +32,9 @@ class ChoreBot(): db_file=None, bot_prefix='!chore'): + logging.basicConfig(filename='matrix-chore-bot.log', encoding='utf-8', level=logging.DEBUG) + + creds = botlib.Creds(matrix_server, bot_name, bot_pwd) self.bot = botlib.Bot(creds) self.prefix = bot_prefix