[PATCH] Add DpkgTerminalLog to APPORT_FILES

Bug #382589 reported by Leann Ogasawara
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
apport (Ubuntu)
Fix Released
Medium
Martin Pitt

Bug Description

Binary package hint: apport

I'm actually using apport - 1.0+launchpadlib1-0ubuntu2 from pitti's apport-retracer PPA (https://edge.launchpad.net/~pitti/+archive/apport-retracer) since it's been converted to use launchpadlib. I had written an ubuntu-bugpattern and was trying to test it using the newly added test-local script (see bug 231013):

ogasawara@emiko:~/ubuntu-bugpatterns$ bzr diff linux.xml
=== modified file 'linux.xml'
--- linux.xml 2009-05-28 16:33:22 +0000
+++ linux.xml 2009-06-01 22:50:16 +0000
@@ -8,4 +8,7 @@
         <re key="ProcCmdLine">loop=/hostname/disks/home/username.disk</re>
  <re key="ErrorMessage">^unable to make backup link of.*before installing new version: Operation not permitted$</re>
     </pattern>
+ <pattern url="https://launchpad.net/bugs/269539">
+ <re key="DpkgTerminalLog">The file `/var/run/grub/menu.lst.ucf-new' has a record of the failed merge of the configuration file.</re>
+ </pattern>
 </patterns>

Unfortunately, test-local would return "No match" because APPORT_FILES defined in apport-1.0+launchpadlib1/apport/crashdb_impl/launchpad.py didn't include DpkgTerminalLog.txt or DpkgTerminalLog.gz in the list of attachment names to examine:

ogasawara@emiko:~/ubuntu-bugpatterns$ ./test-local 331323
No match

After updating APPORT_FILES to check for DpkgTerminalLog.txt and DpkgTerminalLog.gz the test-local script passes:

ogasawara@emiko:~/ubuntu-bugpatterns$ ./test-local 331323
Matched bug pattern: https://launchpad.net/bugs/269539

Patch attached. Thanks.

ProblemType: Bug
Architecture: i386
DistroRelease: Ubuntu 9.04
Package: apport 1.0+launchpadlib1-0ubuntu2
PackageArchitecture: all
ProcEnviron:
 PATH=(custom, user)
 LANG=en_US.UTF-8
 SHELL=/bin/bash
SourcePackage: apport
Uname: Linux 2.6.28-11-generic i686
UnreportableReason: This is not a genuine Ubuntu package

Revision history for this message
Leann Ogasawara (leannogasawara) wrote :
Revision history for this message
Brian Murray (brian-murray) wrote :

I received the following error when using test-local with bug 269539:

Traceback (most recent call last):
  File "./test-local", line 14, in <module>
    report = db.download(sys.argv[1])
  File "/usr/lib/python2.6/dist-packages/apport/crashdb_impl/launchpad.py", line 224, in download
    report.load(StringIO(description))
  File "/usr/lib/python2.6/dist-packages/problem_report.py", line 159, in load
    (key, value) = line.split(':', 1)
ValueError: need more than 1 value to unpack

Changed in apport (Ubuntu):
assignee: nobody → Martin Pitt (pitti)
importance: Undecided → Low
status: New → Triaged
Revision history for this message
Martin Pitt (pitti) wrote :

I already had DpkgTerminalLog.txt, I now added DpkgTerminalLog.gz in trunk as well, thanks!

I'll fix the download crash for bug 269539 as well.

Changed in apport (Ubuntu):
status: Triaged → In Progress
importance: Low → Medium
Revision history for this message
Martin Pitt (pitti) wrote :

Fixed download problem as well, in trunk r1453.

Changed in apport (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apport - 1.2.1-0ubuntu2

---------------
apport (1.2.1-0ubuntu2) karmic; urgency=low

  * debian/control: Update Vcs-Bzr: for new location (moved from project
    branch to package branch).
  * Merge bug fixes from trunk:
    - apport-cli: Fix report saving in "bug report" mode. (LP: #353253)
    - Drop "UnsupportableReason" field, it is too similar to
      UnreportableReason and just confusing.
    - ui.py: Check UnreportableReason for run_report_bug() as well.
      (LP: #361359)
    - general-hooks/generic.py: Do not report problems with low free space on
      / or /home. (LP: #381047)
    - launchpad.py: Do not overwrite report['Title'].
    - launchpad.py: Repair support for extra tags.
    - New function apport.hookutils.root_command_output() to run a command as
      root, through gksu/kdesudo/sudo, depending on the desktop environment.
      (Part of UbuntuSpec:desktop-karmic-symptom-based-bug-reporting)
    - launchpad.py: Fetch DpkgTerminalLog. (LP: #382589)
    - launchpad.py: More robust download(), fixes other part of (LP: #382589)
    - problem_report.py: Allow dashes and underscores in key names. Update
      doc/data-format.tex accordingly. (LP: #380811)

 -- Martin Pitt <email address hidden> Tue, 02 Jun 2009 11:59:41 +0200

Changed in apport (Ubuntu):
status: Fix Committed → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.