[New-bugs-announce] [issue35595] Add sys flag to always show full paths in stack traces (instead of relative paths)
Scott Arciszewski
report at bugs.python.org
Thu Dec 27 10:50:04 EST 2018
New submission from Scott Arciszewski <kobrasrealm at gmail.com>:
I have a wsgi script writing to a log file. The contents look like this (truncated):
File "build/bdist.linux-x86_64/egg/trac/ticket/query.py", line 284, in _count
% sql, args)[0][0]
File "build/bdist.linux-x86_64/egg/trac/db/api.py", line 122, in execute
return db.execute(query, params)
File "build/bdist.linux-x86_64/egg/trac/db/util.py", line 128, in execute
cursor.execute(query, params if params is not None else [])
When confronted with this logfile, I have no idea where build/bdist.linux-x86_64 lives. Rather than hoping a well-timed lsof is adequate to catch the actual script path, I'd like to be able to set a sys.flag to always log the real, fullpath of the .py script either instead of, or alongside, the file path.
----------
messages: 332593
nosy: Scott Arciszewski
priority: normal
severity: normal
status: open
title: Add sys flag to always show full paths in stack traces (instead of relative paths)
versions: Python 2.7, Python 3.8
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue35595>
_______________________________________
More information about the New-bugs-announce
mailing list