Added watch and caught some possible errors.

This commit is contained in:
Jeremy Fincher 2004-08-27 09:11:28 +00:00
parent 685eda4a9f
commit afce0547e1

View File

@ -341,6 +341,7 @@ class IrcState(IrcCommandDispatcher):
'kicklen': int,
'awaylen': int,
'silence': int,
'watch': int, # DynastyNet.
})
def _prefixParser(s):
if ')' in s:
@ -358,7 +359,11 @@ class IrcState(IrcCommandDispatcher):
if '=' in arg:
(name, value) = arg.split('=', 1)
converter = self._005converters.get(name, lambda x: x)
self.supported[name] = converter(value)
try:
self.supported[name] = converter(value)
except Exception, e:
log.exception('Uncaught exception in 005 converter:')
log.error('Name: %s, Converter: %s', name, converter)
else:
self.supported[arg] = None