-
Notifications
You must be signed in to change notification settings - Fork 2
Logger to Chat Message
The bot is able to redirect messages from the python logging facilities into any conversation. This is a feature intended for both developers and bot administrators - modern plugins tend to favor using the python logger for reporting programmatic and administrative events.
Registered in system plugin: commands.loggertochat
/bot logconfig <plugin/module> <log level>
- Monitors the log for events that arise from the specified
<plugin/module>
, and send a chat message when the event matches or exceeds the<log level>
- A list of plugin/module names is available via
/bot plugininfo
-<plugin/module>
must be the plugins full path e.g.plugins.restrictedadd
,plugins.default
, etc -
<log level>
should be the numerical value or label name based on the python logging levels- It is best to set this at 30/
WARNING
- as most administrative events of interest tend to be emitted at this level - it can be set higher or lower depending on the verbosity of the plugin - Unless you are a developer, the
DEBUG
orINFO
log level is probably too verbose to be useful - Setting
<log level>
to 0 will disable monitoring for the<plugin/module>
- It is best to set this at 30/
- A list of plugin/module names is available via
- Log messages will be redirected into any conversation that is tagged
receive-logs
- To list all logging settings, you can issue the command:
/bot config get logging
(requires Default Commands plugin)
/bot lograise <log level name>
- This is a test command that will "emit" a log message at the specified
<log level name>
(based on python logging levels from thecommands.loggertochat
system module
Some plugins may not necessarily emit the proper log levels for administrative monitoring. If you encounter a plugin that you feel has insufficient logging, please use the Issue Tracker to report it so that action can be taken in a future upgrade.
Plugin List | Developer Reference: [ Intro | Plugins | Sinks | In-built Functionality | [Configuration] (Configuration) ]