✨ extra logging parameter to add plugin identifier

Will allow to identify logged exceptions originating from calling
plugins, but also log plugin identifiers directly in the log message
if so desired.
This commit is contained in:
Gina Häußge committed 2019-04-05 17:47:36 +02:00
1 parent 34c30ed73f
commit b353c4eee2
20 files changed
+177 -95

No files matched your search

+2 -1
View File
@@ -92,7 +92,8 @@ class OctoPrintPluginCommands(click.MultiCommand):
continue
result[name + self.sep + command.name] = command
except:
self._logger.exception("Error while retrieving cli commands for plugin {}".format(name))
self._logger.exception("Error while retrieving cli commands for plugin {}".format(name),
extra=dict(plugin=name))
return result