diff --git a/modules/ircv3_resume.py b/modules/ircv3_resume.py index 3184aa35..148e1dc6 100644 --- a/modules/ircv3_resume.py +++ b/modules/ircv3_resume.py @@ -38,7 +38,7 @@ class Module(ModuleManager.BaseModule): if event["args"][0] == "SUCCESS": resume_channels = event["server"].get_setting("resume-channels", []) - self.log.info("Successfully resumed session", []) + self.log.info("Successfully resumed session") event["server"].cap_started = False elif event["args"][0] == "TOKEN": diff --git a/modules/signals.py b/modules/signals.py index 0be15692..0c195670 100644 --- a/modules/signals.py +++ b/modules/signals.py @@ -47,12 +47,12 @@ class Module(ModuleManager.BaseModule): self._reload_modules() def _reload_config(self): - self.bot.log.info("Reloading config file", []) + self.bot.log.info("Reloading config file") self.bot.config.load() - self.bot.log.info("Reloaded config file", []) + self.bot.log.info("Reloaded config file") def _reload_modules(self): - self.bot.log.info("Reloading modules", []) + self.bot.log.info("Reloading modules") success = [] fail = [] diff --git a/src/Logging.py b/src/Logging.py index 49267086..5c3d873c 100644 --- a/src/Logging.py +++ b/src/Logging.py @@ -49,17 +49,17 @@ class Log(object): warn_handler.setFormatter(formatter) self.logger.addHandler(warn_handler) - def trace(self, message: str, params: typing.List, **kwargs): + def trace(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, LEVELS["trace"], kwargs) - def debug(self, message: str, params: typing.List, **kwargs): + def debug(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, logging.DEBUG, kwargs) - def info(self, message: str, params: typing.List, **kwargs): + def info(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, logging.INFO, kwargs) - def warn(self, message: str, params: typing.List, **kwargs): + def warn(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, logging.WARN, kwargs) - def error(self, message: str, params: typing.List, **kwargs): + def error(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, logging.ERROR, kwargs) - def critical(self, message: str, params: typing.List, **kwargs): + def critical(self, message: str, params: typing.List=None, **kwargs): self._log(message, params, logging.CRITICAL, kwargs) def _log(self, message: str, params: typing.List, level: int, kwargs: dict): - self.logger.log(level, message, *params, **kwargs) + self.logger.log(level, message, *(params or []), **kwargs)