diff pytouhou/vm/anmrunner.py @ 575:e4c9eafab6d0

Don’t log every instruction executed, nobody is interested in that, and demote unhandled opcodes to debug.
author Emmanuel Gil Peyrot <linkmauve@linkmauve.fr>
date Sat, 26 Jul 2014 14:46:03 +0200
parents 59bd29568753
children e15672733c93
line wrap: on
line diff
--- a/pytouhou/vm/anmrunner.py
+++ b/pytouhou/vm/anmrunner.py
@@ -88,10 +88,9 @@ class ANMRunner(object):
                 try:
                     callback = self.handlers[opcode]
                 except KeyError:
-                    logger.warn('unhandled opcode %d (args: %r)', opcode, args)
+                    logger.debug('[%d - %04d] unhandled opcode %d (args: %r)',
+                                 id(self), self.frame, opcode, args)
                 else:
-                    logger.debug('[%d - %04d] anm_%d%r', id(self),
-                                 self.frame, opcode, args)
                     callback(self, *args)
                     self._sprite.changed = True