[Bug 846044] Re: software-center crashed with UnicodeEncodeError in get_dbus_message(): 'ascii' codec can't encode character u'\xfc' in position 65: ordinal not in range(128)

Daniel Manrique daniel.manrique at canonical.com
Mon Sep 12 16:57:47 UTC 2011


I did a bit more looking into this problem. This gets triggered if a
transaction error occurs while trying to install the package. This
generates an exception, and it is handling the exception's translated
message string that the crash occurs, due to using the ascii codec to
encode a unicode that contains characters above code 127. Mousetrap
triggers this because it tries to install gnome-mousetrap which has a
dependency problem. So I guess the common denominator in packages that
trigger this problem is that they all generate an error while
installing, due to dependency problems or possibly other factors.

This is visible in the terminal from which software-center is run when
trying to install mousetrap:

2011-09-12 12:47:27,097 - softwarecenter.backend - ERROR - error in _on_trans_finished 'Fehler: Die Paketabhängigkeiten können nicht aufgelöst werden
Dieser Fehler könnte durch weitere erforderliche Software-Pakete, die jedoch fehlen oder nicht installiert werden können, verursacht worden sein. Außerdem könnte es einen Konflikt zwischen Paketen geben, die nicht zur selben Zeit installiert sein dürfen.

Die folgenden Pakete haben nicht erfüllte Abhängigkeiten:

gnome-mousetrap: Depends: python (>= 2.6) aber 2.7.2-5ubuntu1 soll installiert werden
                 Depends: python-support (>= 0.90.0) aber 1.0.13ubuntu1 soll installiert werden

Now, I tried setting the default encoding for the system in
/usr/lib/python2.7/sitecustomize.py by adding:

import sys
sys.setdefaultencoding('utf8')

If I do this, I still see the above error message, as the dependency
problem still remains, but I do not get the UnicodeEncodeError exception
that was happening in software-center.

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

Title:
  software-center crashed with UnicodeEncodeError in get_dbus_message():
  'ascii' codec can't encode character u'\xfc' in position 65: ordinal
  not in range(128)

Status in “aptdaemon” package in Ubuntu:
  Triaged

Bug description:
  I've tried to install an program. After clicking on "install" and
  entered password, the software center crashes.

  ProblemType: Crash
  DistroRelease: Ubuntu 11.10
  Package: software-center 4.1.22
  ProcVersionSignature: Ubuntu 3.0.0-10.16-generic-pae 3.0.4
  Uname: Linux 3.0.0-10-generic-pae i686
  NonfreeKernelModules: fglrx
  ApportVersion: 1.22.1-0ubuntu2
  Architecture: i386
  Date: Fri Sep  9 23:31:38 2011
  ExecutablePath: /usr/share/software-center/software-center
  InstallationMedia: Ubuntu 11.10 "Oneiric Ocelot" - Beta i386 (20110901)
  InterpreterPath: /usr/bin/python2.7
  PackageArchitecture: all
  ProcCmdline: /usr/bin/python /usr/bin/software-center
  ProcEnviron:
   PATH=(custom, no user)
   LANG=de_DE.UTF-8
   SHELL=/bin/bash
  PythonArgs: ['/usr/bin/software-center']
  SourcePackage: software-center
  Title: software-center crashed with UnicodeEncodeError in get_dbus_message(): 'ascii' codec can't encode character u'\xfc' in position 65: ordinal not in range(128)
  UpgradeStatus: No upgrade log present (probably fresh install)
  UserGroups: adm admin cdrom dialout lpadmin plugdev sambashare

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




More information about the foundations-bugs mailing list