[Bug 1013171] Re: Many package hooks not ported to python3

Edward Donovan launchpad at numble.net
Thu Jun 28 01:42:05 UTC 2012


gnome-control-center's apport hook breaks under python 3, as reported in
bug 1018357, now duped here.  Here is a one-line patch that fixes this
error.  And here's the original report pasted in from that bug:

On Quantal up to date
TEST CASE:
1. From a terminal run:
  $ ubuntu-bug gnome-control-center

RESULT:
ERROR: hook /usr/share/apport/package-hooks//source_gnome-control-center.py crashed:
Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport/report.py", line 799, in add_hooks_info
    symb['add_info'](self, ui)
TypeError: add_info() takes exactly 1 positional argument (2 given)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/apport/report.py", line 804, in add_hooks_info
    symb['add_info'](self)
  File "/usr/share/apport/package-hooks//source_gnome-control-center.py", line 6, in add_info
    if report.has_key("Stacktrace") and "/usr/lib/control-center-1" in report["Stacktrace"]:
AttributeError: 'Report' object has no attribute 'has_key'


** Patch added: "python3 patch for gnome-control-center's apport hook"
   https://bugs.launchpad.net/ubuntu/quantal/+source/gnome-control-center/+bug/1013171/+attachment/3206237/+files/gnome-control-center.patch

-- 
You received this bug notification because you are a member of Ubuntu
Foundations Bugs, which is subscribed to mdadm in Ubuntu.
https://bugs.launchpad.net/bugs/1013171

Title:
  Many package hooks not ported to python3

Status in “apport” package in Ubuntu:
  Fix Released
Status in “apport-symptoms” package in Ubuntu:
  Fix Released
Status in “bluez” package in Ubuntu:
  Fix Released
Status in “cairo-dock” package in Ubuntu:
  Fix Released
Status in “chromium-browser” package in Ubuntu:
  Confirmed
Status in “connman” package in Ubuntu:
  Confirmed
Status in “dkms” package in Ubuntu:
  Fix Released
Status in “gnome-control-center” package in Ubuntu:
  Confirmed
Status in “indicator-applet” package in Ubuntu:
  Confirmed
Status in “libatasmart” package in Ubuntu:
  Fix Released
Status in “lxpanel” package in Ubuntu:
  Confirmed
Status in “mdadm” package in Ubuntu:
  Fix Released
Status in “mysql-5.5” package in Ubuntu:
  Confirmed
Status in “mythtv” package in Ubuntu:
  Fix Released
Status in “network-manager” package in Ubuntu:
  Fix Committed
Status in “shadow” package in Ubuntu:
  Fix Released
Status in “udisks2” package in Ubuntu:
  Fix Released
Status in “xdiagnose” package in Ubuntu:
  Fix Released
Status in “apport” source package in Quantal:
  Fix Released
Status in “apport-symptoms” source package in Quantal:
  Fix Released
Status in “bluez” source package in Quantal:
  Fix Released
Status in “cairo-dock” source package in Quantal:
  Fix Released
Status in “chromium-browser” source package in Quantal:
  Confirmed
Status in “connman” source package in Quantal:
  Confirmed
Status in “dkms” source package in Quantal:
  Fix Released
Status in “gnome-control-center” source package in Quantal:
  Confirmed
Status in “indicator-applet” source package in Quantal:
  Confirmed
Status in “libatasmart” source package in Quantal:
  Fix Released
Status in “lxpanel” source package in Quantal:
  Confirmed
Status in “mdadm” source package in Quantal:
  Fix Released
Status in “mysql-5.5” source package in Quantal:
  Confirmed
Status in “mythtv” source package in Quantal:
  Fix Released
Status in “network-manager” source package in Quantal:
  Fix Committed
Status in “shadow” source package in Quantal:
  Fix Released
Status in “udisks2” source package in Quantal:
  Fix Released
Status in “xdiagnose” source package in Quantal:
  Fix Released

Bug description:
  Since the description here is the only post that can be updated, it
  seems the best place to keep a changing list of packages that need
  examining.  (The original description was brief, and about only one
  package.)

  We've fixed all the packages that found in the apt logs uploaded in
  the first round of breakage.  Now I've tried to review all the other
  apport hooks I could find in Quantal.  Working from the archive's
  Contents file, I got the list of packages that have files under
  /usr/share/apport/package-hooks .  I skipped the packages already
  fixed above, and those that were on my system, during the first round
  of breakage, and had no problems.  For the rest, I downloaded the
  debs, extracted the apport hooks, and ran '2to3' on them.  I've posted
  patches for every package that broke under python3.

  Thanks - Edward Donovan <edward.donovan at numble.net>

  These packages didn't break during the apport upgrade that forced a
  recompile, but they get warnings from the 2to3 tool:

    compiz-core
    eclipse-platform
    gnome-control-center-data
    gnome-settings-daemon
    grub-common
    nautilus-data
    unity-common
    apache2.2-common

  Now we have a bug report for at least gnome-control-center, bug
  1018537, which I've duped here.  So these may need patching, too.

  Side note:

    rss-glx: the python is fine, but the hook file is just named
  'source', with no package name or extension, so I filed bug 1017780
  about that.

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/apport/+bug/1013171/+subscriptions




More information about the foundations-bugs mailing list