summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLars Wirzenius <liw@liw.fi>2015-04-18 18:00:26 +0300
committerLars Wirzenius <liw@liw.fi>2015-04-18 18:00:31 +0300
commit2eaa6c539b241c81901a74d809ff5ad2f3d68b82 (patch)
treee4da67fdae368cfd27af28721c09b24bf428e21f
parentce813294cc22930a44570580ba5844f83b1fcbab (diff)
downloadpython-tracing-2eaa6c539b241c81901a74d809ff5ad2f3d68b82.tar.gz
Remove trailing whitespace
-rw-r--r--tracing.py20
1 files changed, 10 insertions, 10 deletions
diff --git a/tracing.py b/tracing.py
index b934c27..f01b1d8 100644
--- a/tracing.py
+++ b/tracing.py
@@ -34,20 +34,20 @@ This module provides a way to achieve that. For example::
# in the main program
import tracing
-
+
tracing.trace_add_pattern('foobar')
tracing.trace_add_pattern('yeehaa')
-
+
...
-
+
# in some other module
tracing.trace('start procedure')
tracing.trace('arg1=%s', arg1)
tracing.trace('arg2=%s', arg2)
-
+
Only calls that happen in files whose names contain ``foobar`` or
``yeehaa`` will actually be logged. Pattern matching is based on
-substring checking only, for speed, so there is no globbing or
+substring checking only, for speed, so there is no globbing or
regular expression matching.
'''
@@ -67,13 +67,13 @@ trace_cache = set()
def trace_add_pattern(pattern):
'''Add a module name pattern.'''
trace_patterns.append(pattern)
-
-
+
+
def trace_clear_patterns():
'''Remove all module name patterns.
-
+
After this, nothing will be traced. This is also the initial state.
-
+
'''
del trace_patterns[:]
trace_cache.clear()
@@ -84,7 +84,7 @@ def trace(msg, *args):
If any arguments are given, the message is formatted as if
with ``msg % args``, otherwise the message is written out as is.
-
+
'''
if trace_patterns: