mirror of
https://github.com/Mikaela/Limnoria.git
synced 2025-01-23 10:34:19 +01:00
better error message.
This commit is contained in:
parent
11de062c20
commit
0525325289
14
src/Owner.py
14
src/Owner.py
@ -111,11 +111,15 @@ def loadPluginClass(irc, module, register=None):
|
||||
try:
|
||||
cb = module.Class()
|
||||
except AttributeError, e:
|
||||
raise callbacks.Error, 'This plugin module doesn\'t have a "Class" ' \
|
||||
'attribute to specify which plugin should be ' \
|
||||
'instantiated. If you didn\'t write this ' \
|
||||
'plugin, but received it with Supybot, file ' \
|
||||
'a bug with us about this error. %s.' % e
|
||||
if 'Class' in str(e):
|
||||
raise callbacks.Error, \
|
||||
'This plugin module doesn\'t have a "Class" ' \
|
||||
'attribute to specify which plugin should be ' \
|
||||
'instantiated. If you didn\'t write this ' \
|
||||
'plugin, but received it with Supybot, file ' \
|
||||
'a bug with us about this error.'
|
||||
else:
|
||||
raise
|
||||
plugin = cb.name()
|
||||
public = True
|
||||
if hasattr(cb, 'public'):
|
||||
|
Loading…
Reference in New Issue
Block a user