report['UnreportableReason'] set before calling report.add_hooks_info

Bug #517272 reported by Severin H
22
This bug affects 4 people
Affects Status Importance Assigned to Milestone
LottaNZB
Invalid
Undecided
Unassigned
apport (Ubuntu)
Fix Released
High
Martin Pitt

Bug Description

Binary package hint: apport

I'm currently updating the Apport hook of the Launchpad-hosted project LottaNZB as APPORT_REPORT_THIRD_PARTY isn't supported anymore.

However, following the instructions at https://wiki.ubuntu.com/Apport/DeveloperHowTo didn't work as intended. I added a proper lottanzb-crashdb.conf file to /etc/apport/crashdb.conf.d and the following lines of code to the hook:

if not apport.packaging.is_distro_package(report['Package'].split()[0]):
    report['ThirdParty'] = 'True'
    report['CrashDB'] = 'lottanzb'

This doesn't work because the hook hasn't been called yet when evaluating

'CrashDB' not in report

in ui.py.

What I suggest is to execute

    if report.add_hooks_info(ui):
        sys.exit(0)

earlier so that 'CrashDB' can be set by the hook in time.

ProblemType: Bug
ApportLog:

Architecture: amd64
CrashReports:
 600:1000:1000:52464:2010-02-04 21:17:36.237123000 +0100:2010-02-04 21:45:02.145867658 +0100:/var/crash/_usr_bin_lottanzb.1000.crash
 600:1000:1000:5145710:2010-01-31 01:31:09.883974000 +0100:2010-02-04 20:40:42.595882810 +0100:/var/crash/_usr_lib_nspluginwrapper_i386_linux_npviewer.bin.1000.crash
 600:1000:1000:1919345:2010-02-04 14:11:38.423985000 +0100:2010-02-04 14:11:42.542734077 +0100:/var/crash/_usr_bin_evince.1000.crash
 600:1000:1000:2440384:2010-01-29 15:23:52.733977000 +0100:2010-02-04 20:40:42.585886637 +0100:/var/crash/_usr_bin_texmaker.1000.crash
Date: Thu Feb 4 21:58:15 2010
DistroRelease: Ubuntu 10.04
InstallationMedia: Ubuntu 10.04 "Lucid Lynx" - Alpha amd64 (20100113)
Package: apport 1.12-0ubuntu3
PackageArchitecture: all
ProcEnviron:
 LANG=de_CH.utf8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.32-12.16-generic
SourcePackage: apport
Uname: Linux 2.6.32-12-generic x86_64

Revision history for this message
Severin H (severinh) wrote :
Revision history for this message
Severin H (severinh) wrote :

This bug has been introduced in revision 1663.

Revision history for this message
Severin H (severinh) wrote :

I'm pretty sure that ubuntuone-client is affected by this bug as well, as it makes use of report['ThirdParty'] and report['CrashDB'].

Severin H (severinh)
description: updated
Revision history for this message
Martin Pitt (pitti) wrote :

Argh, sorry about that. I can indeed reproduce the problem with ubuntuone-client.

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

trunk r1733

Changed in apport (Ubuntu):
status: In Progress → Fix Committed
Revision history for this message
Severin H (severinh) wrote :

Thanks for taking care of it, Martin.

Changed in lottanzb:
status: New → Invalid
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package apport - 1.13.1-0ubuntu1

---------------
apport (1.13.1-0ubuntu1) lucid; urgency=low

  [ Martin Pitt ]
  * New upstream bug fix release:
    - Update parse-segv to handle gdb 7.1 output.
    - Enhance test suite to work with gdb 7.1 as well, and catch future
      outputs.
    - UI: Add exception string to the "network error" dialog, to better tell
      what the problem is.
    - UI: Add back -p option to apport-collect/apport-update-bug (regression
      from 1.13). (LP: #538944)
    - launchpad.py: Add yet another workaround for LP#336866. (LP: #516381)
    - launchpad.py, download(): Ignore attachments with invalid key names.
    - Fix regression from 1.10 which made it impossible for a package hook to
      set a third-party crash database for non-native packages. (LP: #517272)
    - apport-cli: Create the 'details' string only if user wants to view
      details, and do not show files larger than 1MB. Thanks Scott Moser!
      (LP: #486122)
    - packaging-apt-dpkg.py: Silence apt.Cache() spewage to stdout with newer
      python-apt versions. (LP: #531518)
    - unkillable_shutdown: Add list of running processes and blacklisted pids
      to report. (LP: #537262)
    - Sort the report by key in the details view. (LP: #519416)

  [ Evan Dandrea ]
  * Move ubiquity's package-hook into apport, so that it can be used
    from the installed system to grab the logs in /var/log/installer.
 -- Martin Pitt <email address hidden> Sat, 20 Mar 2010 22:28:44 +0100

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.