software-center crashed with UnboundLocalError in install(): local variable 'trans' referenced before assignment

Bug #1044900 reported by Pedro Nunes on 2012-09-02
36
This bug affects 6 people
Affects Status Importance Assigned to Milestone
aptdaemon (Ubuntu)
Undecided
david russell
software-center (Ubuntu)
Critical
Unassigned

Bug Description

Hello

So since i was trying this version, like normal i experience some bugs, all of them was corrected, which i am impressed and want to give you all a gratz..

So i was about to install spacechem which i getted the .Deb from humble bundle.

It open the software center with the description of the package, and i click install.
After that appears the window to report a bug because software center crashed..

I tested 2 or 3 times, i didnt test with other game yet..

I have an Asus 1000H netbook

ProblemType: Crash
DistroRelease: Ubuntu 12.10
Package: software-center 5.3.10
ProcVersionSignature: Ubuntu 3.5.0-13.14-generic 3.5.3
Uname: Linux 3.5.0-13-generic i686
ApportVersion: 2.5.1-0ubuntu4
Architecture: i386
CrashCounter: 1
Date: Sun Sep 2 06:24:23 2012
ExecutablePath: /usr/share/software-center/software-center
InstallationMedia: Ubuntu 12.10 "Quantal Quetzal" - Alpha i386 (20120724.2)
InterpreterPath: /usr/bin/python2.7
PackageArchitecture: all
ProcCmdline: /usr/bin/python /usr/bin/software-center /home/username/Transferências/SpaceChem-i386.deb
ProcEnviron:
 LANGUAGE=pt:pt_BR:en
 PATH=(custom, no user)
 LANG=pt_PT.UTF-8
 SHELL=/bin/bash
PythonArgs: ['/usr/bin/software-center', '/home/username/Transfer\xc3\xaancias/SpaceChem-i386.deb']
SourcePackage: software-center
Title: software-center crashed with UnboundLocalError in install(): local variable 'trans' referenced before assignment
UpgradeStatus: No upgrade log present (probably fresh install)
UserGroups: adm cdrom dip lpadmin plugdev sambashare sudo

Related branches

Pedro Nunes (nunes-p89) wrote :
tags: removed: need-duplicate-check
Changed in software-center (Ubuntu):
importance: Undecided → Medium
Michael Vogt (mvo) wrote :

The log has:
"""
2012-09-02 06:24:10,960 - softwarecenter.db.pkginfo_impl.aptcache - ERROR - simulate failed
Traceback (most recent call last):
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1595, in on_error
    error.raise_exception()
  File "/usr/lib/python2.7/dist-packages/defer/__init__.py", line 487, in _inline_callbacks
    result.traceback)
  File "/usr/lib/python2.7/dist-packages/aptdaemon/client.py", line 1630, in _run_transaction_helper
    tid = yield deferred
DBusException: org.freedesktop.DBus.Python.UnicodeDecodeError: Traceback (most recent call last):
  File "/usr/lib/python3/dist-packages/defer/__init__.py", line 483, in _inline_callbacks
    result = gen.throw(excep)
  File "/usr/lib/python3/dist-packages/aptdaemon/core.py", line 1485, in _create_trans
    yield policykit1.get_proc_info_from_dbus_name(sender, self.bus)
  File "/usr/lib/python3/dist-packages/defer/__init__.py", line 487, in _inline_callbacks
    result = gen.send(result)
  File "/usr/lib/python3/dist-packages/aptdaemon/policykit1.py", line 157, in get_proc_info_from_dbus_name
    cmdline = cmdline_file.read()
  File "/usr/lib/python3.2/encodings/ascii.py", line 26, in decode
    return codecs.ascii_decode(input, self.errors)[0]
UnicodeDecodeError: 'ascii' codec can't decode byte 0xc3 in position 68: ordinal not in range(128)
"""
So this appears to be also a aptdaemon issue.

visibility: private → public
Changed in software-center (Ubuntu):
status: New → In Progress
Michael Vogt (mvo) wrote :

Looks releated to bug #1043752:

I can reproduce this with:
$ mkdir /tmp/ää
$ cd /tmp/ää
$ apt-get download 2vcard
$ software-center /tmp/ää/2vcard*.deb
this will also give me a crash.

Changed in software-center (Ubuntu):
status: In Progress → Fix Committed
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in aptdaemon (Ubuntu):
status: New → Confirmed
Changed in aptdaemon (Ubuntu):
assignee: nobody → david russell (davidrussell1232)
Launchpad Janitor (janitor) wrote :

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

---------------
software-center (5.3.11) quantal; urgency=low

  [ Michael Vogt ]
  * lp:~mvo/software-center/speedup2:
    - startup time improvements
  * lp:~mvo/software-center/adt-you-make-my-life-hard:
    - updates to make the tests run as user
  * debian/tests/run-tests, run-tests.sh:
    - ensure there is a apt-xapian-index available as this is not
      automatically created in the ADT test VM environment
    - fail to run the tests if there is no apt-xapian-index
  * lp:~mvo/software-center/lp1045330:
    - return an empty string if there is no price instead
      of the "None" string and add test (LP: #1045330)
  * lp:~mvo/software-center/lp1044900:
    - add local "trans" var to fix crash (LP: #1044900)
  * lp:~mvo/software-center/fix-init:
    - fix some incorrect __init__() calls
  * lp:~mvo/software-center/fix-fixme-lp1045330:
    - test case update, fix a FIXME in the dataprovider
      test by providing its own private dbus connection
      instead of using the system bus
  * lp:~mvo/software-center/lp1045826:
    - fix double display of currency and cleanup around
      this code (LP: #1045826)
  * lp:~mvo/software-center/trivial-restore-state-fix:
    - improvements to the initial window size code and
      make the window size config a property that supports
      tuples

  [ Aaron Peachey ]
  * lp:~aaronp/software-center/review-refactor:
    - This branch simply converts the existing callbacks for retrieval
      of review data and submission/deletion/modification of reviews
      to GObject signals (courtesy of mvo) which makes it more consistent
      with the rest of the code

  [ Gary Lasker ]
  * lp:~gary-lasker/software-center/recommended-installed-feedback:
    - signal the recommender service when a recommended item has been
      successfully installed, refactor and clean up surrounding code,
      new unit tests for the feature (LP: #944060, LP: #1044107)
 -- Michael Vogt <email address hidden> Fri, 07 Sep 2012 09:36:45 +0200

Changed in software-center (Ubuntu):
status: Fix Committed → Fix Released
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package aptdaemon - 0.45+bzr856-0ubuntu1

---------------
aptdaemon (0.45+bzr856-0ubuntu1) quantal; urgency=low

  * New upstream snapshot:
    - pkcompat: Fix get_files() LP: #1040619 (thanks to Martin Pitt)
    - Fix crash when run inside non-ascii dirs LP: #1044900
    - Fix crash in widget's diff view if a @@ line does not have a range
      LP: #875879 (thanks to Brian Murray)
    - Support credentials change when adding a repository that is already
      in sources.list/auth.conf
 -- Michael Vogt <email address hidden> Fri, 07 Sep 2012 10:20:10 +0200

Changed in aptdaemon (Ubuntu):
status: Confirmed → Fix Released
Dave Morley (davmor2) on 2012-10-02
Changed in software-center (Ubuntu):
importance: Medium → Critical
tags: added: ca-escalated
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers