apport-hackers team mailing list archive
-
apport-hackers team
-
Mailing list archive
-
Message #00319
[Merge] lp:~bdrung/apport/lp-1686387 into lp:apport
Benjamin Drung has proposed merging lp:~bdrung/apport/lp-1686387 into lp:apport.
Requested reviews:
Apport upstream developers (apport-hackers)
Related bugs:
Bug #1686387 in Apport: "Please strip root directory (from sandbox) from stack traces"
https://bugs.launchpad.net/apport/+bug/1686387
For more details, see:
https://code.launchpad.net/~bdrung/apport/lp-1686387/+merge/389657
When using a sandbox directory, the root directory of the sandbox can be seen in the stack traces.
--
Your team Apport upstream developers is requested to review the proposed merge of lp:~bdrung/apport/lp-1686387 into lp:apport.
=== modified file 'apport/report.py'
--- apport/report.py 2020-06-09 21:41:57 +0000
+++ apport/report.py 2020-08-21 14:59:18 +0000
@@ -785,6 +785,12 @@
else:
del self['AssertionMessage']
+ if rootdir:
+ # Strip root directory (from sandbox) from stack traces
+ for key in ("Stacktrace", "ThreadStacktrace"):
+ if key in self:
+ self[key] = self[key].replace("from " + rootdir, "from ")
+
if 'Stacktrace' in self:
self._gen_stacktrace_top()
addr_signature = self.crash_signature_addresses()