mirror of
https://github.com/Mikaela/Limnoria.git
synced 2024-11-27 13:19:24 +01:00
Add some more assertion messages.
This commit is contained in:
parent
2c96a65704
commit
7c5463dd3e
@ -192,7 +192,8 @@ class Owner(callbacks.Plugin):
|
|||||||
conf.registerNetwork(network, password)
|
conf.registerNetwork(network, password)
|
||||||
serverS = '%s:%s' % serverPort
|
serverS = '%s:%s' % serverPort
|
||||||
conf.supybot.networks.get(network).servers.append(serverS)
|
conf.supybot.networks.get(network).servers.append(serverS)
|
||||||
assert conf.supybot.networks.get(network).servers()
|
assert conf.supybot.networks.get(network).servers(), \
|
||||||
|
'No servers are set for the %s network.' % network
|
||||||
self.log.info('Creating new Irc for %s.', network)
|
self.log.info('Creating new Irc for %s.', network)
|
||||||
newIrc = irclib.Irc(network)
|
newIrc = irclib.Irc(network)
|
||||||
for irc in world.ircs:
|
for irc in world.ircs:
|
||||||
|
@ -101,7 +101,8 @@ def loadPluginClass(irc, module, register=None):
|
|||||||
if hasattr(cb, 'public'):
|
if hasattr(cb, 'public'):
|
||||||
public = cb.public
|
public = cb.public
|
||||||
conf.registerPlugin(plugin, register, public)
|
conf.registerPlugin(plugin, register, public)
|
||||||
assert not irc.getCallback(plugin)
|
assert not irc.getCallback(plugin), \
|
||||||
|
'There is already a %r plugin registered.' % plugin
|
||||||
try:
|
try:
|
||||||
renames = []#XXX registerRename(plugin)()
|
renames = []#XXX registerRename(plugin)()
|
||||||
if renames:
|
if renames:
|
||||||
|
Loading…
Reference in New Issue
Block a user