Removed log.stat, it was dumb.

This commit is contained in:
Jeremy Fincher 2005-02-15 06:49:51 +00:00
parent 1193890c36
commit c09a7cace1
2 changed files with 0 additions and 11 deletions

View File

@ -340,7 +340,6 @@ def tokenize(s, channel=None):
start = time.time()
try:
ret = Tokenizer(brackets=brackets,pipe=pipe,quotes=quotes).tokenize(s)
log.stat('tokenize took %s seconds.' % (time.time() - start))
return ret
except ValueError, e:
raise SyntaxError, str(e)
@ -1065,7 +1064,6 @@ class Commands(object):
self.log.debug('Error return: %s', utils.gen.exnToString(e))
irc.error(str(e))
elapsed = time.time() - start
log.stat('%s took %s seconds', name, elapsed)
def getCommandHelp(self, name):
name = canonicalName(name)

View File

@ -222,11 +222,6 @@ conf.registerGlobalValue(conf.supybot.log, 'level',
LogLevel(logging.INFO, """Determines what the minimum priority level logged
will be. Valid values are DEBUG, INFO, WARNING, ERROR,
and CRITICAL, in order of increasing priority."""))
conf.registerGlobalValue(conf.supybot.log, 'statistics',
ValidLogLevel(-1, """Determines what level statistics reporting
is to be logged at. Mostly, this just includes, for instance, the time it
took to parse a message, process a command, etc. You probably don't care
about this."""))
conf.registerGlobalValue(conf.supybot.log, 'timestampFormat',
registry.String('%Y-%m-%dT%H:%M:%S', """Determines the format string for
timestamps in logfiles. Refer to the Python documentation for the time
@ -278,10 +273,6 @@ exception = _logger.exception
registry.error = error
registry.exception = exception
def stat(*args):
level = conf.supybot.log.statistics()
_logger.log(level, *args)
setLevel = _logger.setLevel
atexit.register(logging.shutdown)