diff options
author | Lars Wirzenius <liw@liw.fi> | 2011-02-15 23:47:46 +0000 |
---|---|---|
committer | Lars Wirzenius <liw@liw.fi> | 2011-02-15 23:47:46 +0000 |
commit | 5354b83cedaad3fb31c22bff65750b01f29bc350 (patch) | |
tree | e156cbb8a45d788bcf43a76de281dea19087464d /tracing.py | |
parent | 9ec4c1dab031f14041dd363428100136f7079fa3 (diff) | |
download | python-tracing-5354b83cedaad3fb31c22bff65750b01f29bc350.tar.gz |
New version with API improvemnt: trace now takes optional arguments
and if given any, they'll be used to format message.
Diffstat (limited to 'tracing.py')
-rw-r--r-- | tracing.py | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -74,5 +74,6 @@ def trace(msg, *args): break if log_it: filename = os.path.basename(filename) - msg = msg % args + if args: + msg = msg % args logging.debug('%s:%s:%s: %s' % (filename, lineno, funcname, msg)) |