Software-center causes update-apt-xapian-index to fail on downstream distros

Bug #808455 reported by Twisted Lincoln, Inc. on 2011-07-10
10
This bug affects 1 person
Affects Status Importance Assigned to Milestone
software-center (Ubuntu)
Low
Michael Vogt
Precise
Undecided
Unassigned
Quantal
Low
Michael Vogt

Bug Description

When software-center is installed on an Ubuntu derivative (in our case, Nexradix), update-apt-xapian-index fails.

When run, a python error indicating that "no module Nexradix is found"

When I replace lines 112-114 in /usr/share/software-center/softwarecenter/distro/__init__.py with:

distro_id = "Ubuntu"

update-apt-xapian-index works without incident.

Based on the prior code, it appears that the current distro name is being parsed from /etc/lsb-release, and if it doesn't find a matching distro in the "/usr/share/software-center/softwarecenter/distro" directory, it fails.

I assume that adding the distro in question to that directory using Ubuntu.py as a template would likely solve this, however it remains a bug: update-apt-xapian-index should not rely on software-center's distro-specific code, or at the very least, fail more gracefully with an error message or link to documentation as to what the fix is.

Related branches

Kiwinote (kiwinote) on 2011-09-27
tags: added: db
Michael Vogt (mvo) on 2012-04-18
Changed in software-center (Ubuntu):
status: New → In Progress
importance: Undecided → Low
Changed in software-center (Ubuntu):
assignee: nobody → Michael Vogt (mvo)
status: In Progress → Fix Committed

Hello Twisted, or anyone else affected,

Accepted software-center into precise-proposed. The package will build now and be available in a few hours. Please test and give feedback here. See https://wiki.ubuntu.com/Testing/EnableProposed for documentation how to enable and use -proposed. Thank you in advance!

Changed in software-center (Ubuntu Precise):
status: New → Fix Committed
tags: added: verification-needed
Gary Lasker (gary-lasker) wrote :

This is not an easy bug to reproduce as it requires a non-Ubuntu installation to fully test the fix. However, testing for regressions in Ubuntu is straightforward, you need simply start Software Center and insure that the apt-xapian-index is updated without incident.

I have done this testing with the software-center version 5.2.1 in precise-proposed and can verify that it causes no regressions.

Thanks!

tags: added: verification-done
removed: db verification-needed
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package software-center - 5.2.1

---------------
software-center (5.2.1) precise-proposed; urgency=low

  [ Michael Vogt ]
  * lp:~mvo/software-center/lp977179:
    - make the review UI react correctly to conditions of network
      availability (LP: #977179)
  * lp:~mvo/software-center/fix-crash-deb-file-size-calc:
    - fix crash when installing a deb file that is not found in
      the current apt cache
  * lp:~mvo/software-center/lp981992:
    - fix a crash in the new a11y code if there is a row that has
      no data or is not yet preloaded (LP: #981992)
  * lp:~mvo/software-center/fix-gmenu-searcher:
    - fix the menu searcher for non-Unity configurations after
      the app-install-data-ubuntu file layout changed
  * lp:~mvo/software-center/lp808455:
    - trivial fix for crash on downstream distros (LP: #808455)
  * lp:~mvo/software-center/lp927262:
    - fix crash when get_vadjustment() returns None (LP: #927262)
  * lp:~mvo/software-center/utf8-fixes:
    - fix various utf8-related crashes (LP: #943500, LP: #922225,
      LP: #917755)
  * lp:~mvo/software-center/gwibber-utf8-lp985255:
    - fix a utf8 crash in the gwibber integration (LP: #985255)
  * lp:~mvo/software-center/workaround-gtk-regression-lp986186:
    - workaround performance issue with the Gtk.TreeView.set_model()
      call when there is a cell_data_func attached. Not every user is
      affected (settings dependant somehow), but when affected it causes
      a massive performance degration for huge list models like "System"
      (LP: #986186). This branch works around the problem by disconnecting
      the cell_data_func before setting the new model.
  * lp:~mvo/software-center/fix-clear-credentials-race:
    - fix an incorrect use of the sso dbus backend, we now correctly
      wait until it emits a CredentialsCleared signal (LP: #986117)

  [ Gary Lasker ]
  * lp:~gary-lasker/software-center/add-to-launcher-after-auth-lp972710:
    - fix bug where an application will be added to the Unity launcher
      in the case where the user cancels the installation auth dialog
      (LP: #972710)
  * lp:~gary-lasker/software-center/recommendations-sso-login-lp973612:
    - fix bug where the recommendations opt-in panel is hidden if
      the user declines the SSO dialog after opting in (LP: #973612)
    - fix the user experience if the user has previously opted-in to
      recommendations and their SSO token is found have been removed
      or revoked or otherwise found to be invalid (LP: #967064)
    - improve the responsiveness of the spinner in the recommendations
      flow
 -- Michael Vogt <email address hidden> Thu, 26 Apr 2012 09:47:19 +0200

Changed in software-center (Ubuntu Quantal):
status: Fix Committed → Fix Released
Changed in software-center (Ubuntu Precise):
status: Fix Committed → Fix Released

The package update in question does not appear to have fixed this, at least not for me. Running Precise, I upgraded software-center to version 5.2.9, then ran sudo update-apt-xapian-index -vf. I got the same results as reported originally, with the workaround I posted (though now on line 166) having the same effect.

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers