mirror of
https://github.com/jlu5/PyLink.git
synced 2025-02-17 14:01:03 +01:00
ServiceBot: log access denials to warning - closes #593
(backported from commit 655221491cdce25ae292ebfc36721f2ef781b6aa)
This commit is contained in:
parent
d0568a6ad7
commit
7476c6cf05
6
utils.py
6
utils.py
@ -350,7 +350,11 @@ class ServiceBot():
|
|||||||
for func in self.commands[cmd]:
|
for func in self.commands[cmd]:
|
||||||
try:
|
try:
|
||||||
func(irc, source, cmd_args)
|
func(irc, source, cmd_args)
|
||||||
except (NotAuthorizedError, InvalidArgumentsError) as e:
|
except NotAuthorizedError as e:
|
||||||
|
self.reply(irc, 'Error: %s' % e)
|
||||||
|
log.warning('(%s) Denying access to command %r for %s; msg: %s', irc.name, cmd,
|
||||||
|
irc.getHostmask(source), e)
|
||||||
|
except InvalidArgumentsError as e:
|
||||||
self.reply(irc, 'Error: %s' % e)
|
self.reply(irc, 'Error: %s' % e)
|
||||||
except Exception as e:
|
except Exception as e:
|
||||||
log.exception('Unhandled exception caught in command %r', cmd)
|
log.exception('Unhandled exception caught in command %r', cmd)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user