bmotion
bmotion copied to clipboard
Error when enabling Censor plugin
I am trying to enable the censor plugin and I get this error:
[01:37:30 am] « kyrie » [10/30/2019, 01:37:30 AM] bMotion: ALERT! Callback failed for !bmotion: bMotion_plugin_management_plugins: can't read "TEH_ARRAY(censor)": no such element in array [01:37:30 am] « kyrie » [10/30/2019, 01:37:30 AM] Tcl error [bMotion_dcc_command]: invalid command name "bMotion_plugin_find_admin"
How can I fix this so I can get the censor plugin to work?
How are you trying to enable it? That looks like you're hitting an old code path :)
If you do .bmotion plugin enable output censor on the partyline it should enable it. You can check with .bmotion plugin list censor to see it's "[on]". I tested it ok then as below:
.bmotion plugin list censor
Installed bMotion plugins (filtered for 'censor'):
simple:
complex:
output: 90/censor[off] (1)
action_simple:
action_complex:
irc_event:
management:
Total plugins: 1
.bmotion plugin enable output censor
Enabling output plugin censor globally...
...done.
.bmotion plugin list censor
Installed bMotion plugins (filtered for 'censor'):
simple:
complex:
output: 90/censor[on] (1)
action_simple:
action_complex:
irc_event:
management:
Total plugins: 1
1344.29 [ jms] .bmotion nt parse decaf
1344.33 [ NoTopic] BEEP
Note that rehashing your bot will disable the plugin again (as that's the default). You'll need to add it to the "output_preenables" setting (that's with an s on the end, which is different to the sample config, which is wrong), something like censor:1 should do it. Finally don't forget to update the list of "censorwords" in your configuration to your taste.
Also note that the censor plugin isn't guaranteed to get everything, what with typos and all (both ones the bot makes, and ones made by people it learns words from).