summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
authorKarel Klic <kklic@redhat.com>2010-02-04 10:11:40 +0100
committerKarel Klic <kklic@redhat.com>2010-02-04 10:11:40 +0100
commitabf9af670cd605ec2fb631219e9493f619773db3 (patch)
tree63b9acb8fd64790812226d902798a31692392c10 /src
parenteb7483e262e29fdebb676c18453447247f3c0545 (diff)
downloadabrt-abf9af670cd605ec2fb631219e9493f619773db3.tar.gz
abrt-abf9af670cd605ec2fb631219e9493f619773db3.tar.xz
abrt-abf9af670cd605ec2fb631219e9493f619773db3.zip
Skip bugs without backtrace; +some notes; run ./abrt-backtrace instead of system one
Diffstat (limited to 'src')
-rwxr-xr-xsrc/Backtrace/abrt-bz-dupchecker18
1 files changed, 17 insertions, 1 deletions
diff --git a/src/Backtrace/abrt-bz-dupchecker b/src/Backtrace/abrt-bz-dupchecker
index 01cafa01..4484d399 100755
--- a/src/Backtrace/abrt-bz-dupchecker
+++ b/src/Backtrace/abrt-bz-dupchecker
@@ -10,6 +10,14 @@
#
# Please do not run this script unless it's neccessary to do so.
# It forces Bugzilla to send data related to thousands of bug reports.
+#
+#
+# Useful text to be pasted to Bugzilla:
+"""
+This bug appears to have been filled using a buggy version of ABRT, because
+it contains unusable backtrace. Sorry for the inconvenience.
+Closing as INSUFFICIENT_DATA.
+"""
from bugzilla import RHBugzilla
from optparse import OptionParser
@@ -62,16 +70,24 @@ for buginfo in buginfos:
else:
# Get backtrace from bug and store it as a file.
bug = bz.getbug(buginfo.bug_id)
+ downloaded = False
for attachment in bug.attachments:
if attachment['filename'] == 'backtrace':
data = bz.openattachment(attachment['id'])
f = open(filename, 'w')
f.write(data.read())
f.close()
+ downloaded = True
if options.verbose:
print "Attachment {0} downloaded.".format(filename)
+
+ # Silently skip bugs without backtrace.
+ # Those are usually duplicates of bugs; the duplication copies
+ # abrt_hash, but it does not copy the attachment.
+ if not downloaded:
+ continue
- command = ["/usr/bin/abrt-backtrace"]
+ command = ["./abrt-backtrace"]
command.append(filename)
command.append("--single-thread")
command.append("--frame-depth=5")