list view doesn't use correct sorting

Bug #969215 reported by Kiwinote on 2012-03-30
This bug affects 1 person
Affects Status Importance Assigned to Milestone
software-center (Ubuntu)
Gary Lasker

Bug Description

Test case:

- launch s-c
- search for 'ark'
- click on 'all software'
- click on the 'accessories' category
- notice that the combibox states that the list is sorted by top rated - it isn't however, as when sorted by top rated the first result should be 7zip, not minbar

Second test case per mvo's review from a separate bug's merge proposal (

- search for "foo"
- change "by name"
- go back
- go a a category like "accessories" will sort by name, but the combo will show "by top rated"

Related branches

Kiwinote (kiwinote) on 2012-03-30
description: updated
Michael Vogt (mvo) wrote :

It appears that _refresh_apps_with_apt_cache() uses return self.app_view.get_sort_mode() and that returns the wrong

The reason is that display_matches() updates the combobox but get_sort_mode() is called before display_matches so
the combo is still using the old value.

Kiwinote (kiwinote) wrote :

it seems that replacing
in _use_combobox_without_sort_by_search_ranking solves this problem, but it feels slightly dodgy so probs isn't a good solution

Michael Vogt (mvo) on 2012-03-30
Changed in software-center (Ubuntu):
status: New → Triaged
milestone: none → ubuntu-12.04
Changed in software-center (Ubuntu):
assignee: nobody → Gary Lasker (gary-lasker)
status: Triaged → In Progress
description: updated
description: updated
Changed in software-center (Ubuntu):
status: In Progress → Fix Committed
Launchpad Janitor (janitor) wrote :

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

software-center (5.2) precise; urgency=low

  [ Michael Vogt ]
  * debian/control:
    - recommend xz-lmza instead of lzma (LP: #878354)
  * lp:~mvo/software-center/track-axi-changes:
    - add a monitor for changes in the apt-xapian-index to ensure
      the DB is reopened if the cron job changes the apt-xapian-index
      database (LP: #507836)
  * lp:~mvo/software-center/lp970342:
    - do not crash if the parent goes away (and therefore the pipe)
      and the token can not be obtained (LP: #970342)
  * lp:~mvo/software-center/lp967036:
    - fix UnicodeDecodeError crash for apps with hardware
      requirements in the details view (LP: #967036)
  * lp:~mvo/software-center/list-a11y:
    - restore the a11y support for orca/accerciser/ldtp for
      the listview and treeview
  * lp:~mvo/software-center/lp979013:
    - fix a bug in the review display for certain language
      environments (LP: #979013)
  * lp:~mvo/software-center/appview-tweaks:
    - code cleanup in the sortmode code
  * lp:~mvo/software-center/lp772549:
    - fix a bug that can result in a blank software center
      screen on startup (LP: #772549)
  * lp:~mvo/software-center/lp914393:
    - adds an explicit sys.exit() to ensure all gtk event
      processing is stopped on application quit (LP: #914393)
  * lp:~mvo/software-center/lp976169:
    - do not crash if apt-xapian-index is not installed
      (LP: #976337)
    - ignore xapian.DatabaseOpeningError here (happens when
      there is no a-x-i so we don't care) (LP: #976169)
  * lp:~mvo/software-center/lp976525:
    - do not show "upgradable" button when there should be "remove"
      (LP: #976525)

  [ Gary Lasker ]
  * lp:~gary-lasker/software-center/sorting-fix-lp969215:
    - fix sort combo box inconsistencies (LP: #969215)

  [ Dave Morley ]
  * lp:~davmor2/software-center/remove_two_lines:
    - small fixes for test script

  [ Kiwinote ]
  * sc/ui/gtk3/widgets/
    - everyone tries to expand a category in the installed pane by clicking
      on the text rather than the expander arrow (LP: #877130)
 -- Michael Vogt <email address hidden> Fri, 13 Apr 2012 18:35:13 +0200

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

Other bug subscribers