[Python-checkins] cpython: Closes #18671: Output more information when logging exceptions occur.
vinay.sajip
python-checkins at python.org
Thu Aug 8 19:29:06 CEST 2013
http://hg.python.org/cpython/rev/a206f952668e
changeset: 85075:a206f952668e
user: Vinay Sajip <vinay_sajip at yahoo.co.uk>
date: Thu Aug 08 18:28:53 2013 +0100
summary:
Closes #18671: Output more information when logging exceptions occur.
files:
Lib/logging/__init__.py | 3 +++
Misc/NEWS | 2 ++
2 files changed, 5 insertions(+), 0 deletions(-)
diff --git a/Lib/logging/__init__.py b/Lib/logging/__init__.py
--- a/Lib/logging/__init__.py
+++ b/Lib/logging/__init__.py
@@ -899,6 +899,9 @@
# couldn't find the right stack frame, for some reason
sys.stderr.write('Logged from file %s, line %s\n' % (
record.filename, record.lineno))
+ # Issue 18671: output logging message and arguments
+ sys.stderr.write('Message: %r\n'
+ 'Arguments: %s\n' % (record.msg, record.args))
except OSError: #pragma: no cover
pass # see issue 5971
finally:
diff --git a/Misc/NEWS b/Misc/NEWS
--- a/Misc/NEWS
+++ b/Misc/NEWS
@@ -22,6 +22,8 @@
Library
-------
+- Issue #18671: Output more information when logging exceptions occur.
+
- Issue #18621: Prevent the site module's patched builtins from keeping
too many references alive for too long.
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list