From b168b68a641e32b1114d4a5a668b08a01e48c8e6 Mon Sep 17 00:00:00 2001 From: Ned Batchelder Date: Tue, 3 Sep 2019 13:34:39 -0400 Subject: --debug=self now goes on a second line for better readability --- coverage/debug.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'coverage/debug.py') diff --git a/coverage/debug.py b/coverage/debug.py index de5d9319..c5fee683 100644 --- a/coverage/debug.py +++ b/coverage/debug.py @@ -72,11 +72,11 @@ class DebugControl(object): `msg` is the line to write. A newline will be appended. """ + self.output.write(msg+"\n") if self.should('self'): caller_self = inspect.stack()[1][0].f_locals.get('self') if caller_self is not None: - msg = "[self: {!r}] {}".format(caller_self, msg) - self.output.write(msg+"\n") + self.output.write("self: {!r}\n".format(caller_self)) if self.should('callers'): dump_stack_frames(out=self.output, skip=1) self.output.flush() -- cgit v1.2.1