Sfoglia il codice sorgente

hopefully catch command exceptions properly this time

tags/v0.1
Ben Kurtovic 13 anni fa
parent
commit
20ffe4b55a
1 ha cambiato i file con 5 aggiunte e 1 eliminazioni
  1. +5
    -1
      irc/command_handler.py

+ 5
- 1
irc/command_handler.py Vedi File

@@ -58,5 +58,9 @@ def check(hook, data):
for command in commands:
if hook in command.get_hooks():
if command.check(data):
command.process(data)
try:
command.process(data)
except:
print "Error executing command:"
traceback.print_exc() # catch exceptions and print them
break

Caricamento…
Annulla
Salva