Flagging review fails (ValidationException: Argument 'reason' must be a string)

Bug #856429 reported by Matthew Paul Thomas on 2011-09-22
This bug affects 1 person
Affects Status Importance Assigned to Milestone
software-center (Ubuntu)

Bug Description

software-center trunk r2415, Ubuntu 11.10 beta

1. Click the "Inappropriate?" link below a review.
2. Choose a reason, enter some text, and click "Report".

What happens:
* A "Failed to submit" error.
* In ~/.cache/software-center/reviews-helper.log, a traceback:
flag_review failed
Traceback (most recent call last):
  File "./data/report_review_gtk3.py", line 303, in _submit_reports_if_pending
  File "/usr/lib/python2.7/dist-packages/piston_mini_client/validators.py", line 61, in wrapper
    return func(*args, **kwargs)
  File "/usr/lib/python2.7/dist-packages/piston_mini_client/validators.py", line 33, in wrapper
    "Argument '%s' must be a string" % varname)
ValidationException: Argument 'reason' must be a string
Argument 'reason' must be a string

Michael Vogt (mvo) wrote :

The following test program shows the failure:


from gi.repository import Gtk
from gettext import gettext as _

def on_button_clicked(button, combo):
    print combo
    print combo.get_active_text()

if __name__ == "__main__":

    win = Gtk.Window()
    box = Gtk.VBox()

    combo = Gtk.ComboBoxText()
    for term in [ _(u"Please make a selection\u2026"),
                  _("Offensive language"),
                  _("Other") ]:

    button = Gtk.Button("get_active_text")
    button.connect("clicked", on_button_clicked, combo)
    box.pack_start(combo, False, False, 0)
    box.pack_start(button, False, False, 0)
    win.connect("destroy", lambda w: Gtk.main_quit())


if Gtk.ComboBoxText.new() is used instead its fine.

Changed in software-center (Ubuntu):
status: New → In Progress
importance: Undecided → High
Launchpad Janitor (janitor) wrote :
Download full text (3.2 KiB)

This bug was fixed in the package software-center -

software-center ( oneiric; urgency=low

  [ Robert Roth ]
  * Fix inconsistent colors in banner (LP: #855417)
  * softwarecenter/db/debfile.py,
    - display total size in the details view for standalone
      deb files (LP: #851222)
  * softwarecenter/db/database.py:
    - restore support for custom list searches
      (LP: #835069, LP: #828281)

  [ Kiwinote ]
  * correctly index desktop files which refer to packages for which we must
    install a version for a foreign architecture (eg skype)
  * softwarecenter/backend/reviews.py:
    - allow us to write reviews for apps with unicode appname (LP: #856052)

  [ Matthew McGowan ]
  * lp:~mmcg069/software-center/tweaks:
    - mak the avg-rating label white when a row is selected
    - TextBlock.set_visible_window to False. add a css comment
  * lp:~mmcg069/software-center/bug635994-again:
    - make the up/down -arrow behaviour available to both
      detailsview_gtk and the catview_gtk (LP: #635994)
  * lp:~mmcg069/software-center/re-fixes:
    - additional fixes for the detailsview

  [ Gary Lasker ]
  * softwarecenter/ui/gtk3/panes/availablepane.py,
    - prevent potential crash at startup if views have not yet
      been created on a call to refresh_apps (LP: #855622)
  * softwarecenter/ui/gtk3/panes/availablepane.py,
    - consolidate spinner code, add timeout mask for installed
      view spinner
  * softwarecenter/ui/gtk3/panes/softwarepane.py:
    - display spinner while changing list view sort method
  * softwarecenter/ui/gtk3/app.py:
    - display spinner while loading previous purchases list
  * softwarecenter/ui/gtk3/widgets/actionbar.py:
    - fix regression in action bar button alignment (LP: #856872)
  * softwarecenter/ui/gtk3/panes/availablepane.py:
    - restore action bar functionality for custom lists
      (LP: #835069)
    - don't hide technical items during a custom list search
    - restore custom list search using apt url syntax (LP: #828281)
  * softwarecenter/ui/gtk3/dialogs/__init__.py:
    - fix crash when showing error dialog (LP: #842678)

  [ Didier Roche ]
  * lp:~didrocks/software-center/new-oneconf-sync-signal:
    - enable getting a last sync accurate date as soon as the sync
      is done (LP: #855345)

  [ Michael Vogt ]
  * utils/submit_review_gtk3.py:
    - setup logging from the helper to xdg
  * utils/submit_review_gtk3.py, softwarecenter/ui/gtk3/views/appview.py:
    - use Gtk.ComboBoxText.new() instead of Gtk.ComboBoxText(). This makes
      get_active_text() actually work on the combobox (LP: #856429)
  * softwarecenter/utils.py:
    - fix writing new config before using it (LP: #827527)
  * softwarecenter/backend/reviews.py:
    - write out the review stats in a C friendly bsddb so that unity
      can use it too (thanks to Mikkel Kamstrup)
  * softwarecenter/ui/gtk3/panes/availablepane.py:
    - fix endless recursion (LP: #851671)
 -- Michael Vogt <michael.v...


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

Other bug subscribers