computer-janitor-gtk crashed with KeyError in create_column()

Bug #503727 reported by nadasjozef@freemail.hu on 2010-01-06
388
This bug affects 120 people
Affects Status Importance Assigned to Milestone
computer-janitor (Ubuntu)
High
Barry Warsaw
Nominated for Lucid by ROB3RT

Bug Description

Binary package hint: computer-janitor

No comment.

ProblemType: Crash
Architecture: i386
Date: Wed Jan 6 10:36:43 2010
DistroRelease: Ubuntu 10.04
ExecutablePath: /usr/share/computerjanitor/computer-janitor-gtk
InstallationMedia: Ubuntu 9.10 "Karmic Koala" - Release i386 (20091028.5)
InterpreterPath: /usr/bin/python2.6
Package: computer-janitor-gtk 1.14-0ubuntu1
PackageArchitecture: all
ProcCmdline: /usr/bin/python /usr/sbin/computer-janitor-gtk
ProcEnviron:
 PATH=(custom, no user)
 LANG=hu_HU.UTF-8
 SHELL=/bin/bash
ProcVersionSignature: Ubuntu 2.6.32-9.13-generic
PythonArgs: ['/usr/sbin/computer-janitor-gtk']
SourcePackage: computer-janitor
Tags: lucid
Title: computer-janitor-gtk crashed with KeyError in create_column()
Uname: Linux 2.6.32-9-generic i686
UserGroups:

tags: removed: need-duplicate-check
tags: added: bugpattern-needed
Brian Curtis (bcurtiswx) on 2010-01-12
visibility: private → public
tags: added: bugpattern-written
removed: bugpattern-needed

Affects me too, Computer Janitor fails to start - upgraded from Karmic to Lucid.

Changed in computer-janitor (Ubuntu):
status: New → Confirmed
importance: Undecided → Medium

Marking Triaged, Medium. Should be enough debugging information here for a developer to take a look and begin working on the problem. Thank you for reporting this to us!

Changed in computer-janitor (Ubuntu):
status: Confirmed → Triaged

yep, affects me, too
-- is reproducable:
   a) any time i ran the synaptic package manager and do update, when starting computer janitor right after it while synaptic is open and finished with updates
   b) any time after doing a Reload of package information, if update was done or not; window left open, starting janitor it crashes
   c) even if synaptic is closed, starting janitor RIGHT AFTER IT it crashes; in this case it seems synaptic did not closed quickly enough

System is HP Compaq 6715b -- Ubuntu Lucid Lynx in use for real work / production environment, to guarantee real world bug reporting

OS: Ubuntu.10.4.LucidLynx.Alpha.En.Us.x64
CPU: AMD Turion x2 2 Ghz T60
RAM: 4 GB 667 MHz Dual channel DDR 2
HDD: SATA Compact Flash 8 GB SanDisk Ultra III with LVM formatted
FPR: Authentec 2501
etc. if someone needs special info to fix this, leave me a note and i will run necessary tools

Good Luck Brothers.

arky (arky) wrote :

In Ubuntu lucid (development branch) with computer-janitor-gtk version 1.14-0ubuntu1

$ gksu --desktop /usr/share/applications/computer-janitor-gtk.desktop computer-janitor-gtk
Traceback (most recent call last): File "/usr/sbin/computer-janitor-gtk", line 30, in <module>
    app.run(computerjanitorapp.GtkUserInterface)
  File "/usr/share/computerjanitor/computerjanitorapp/app.py", line 101, in run
    ui.run(options, args)
  File "/usr/share/computerjanitor/computerjanitorapp/ui_gtk.py", line 211, in run
    self.create_column('unused_treeview', self.unused_filter)
  File "/usr/share/computerjanitor/computerjanitorapp/ui_gtk.py", line 291, in create_column
    treeview = self.widgets[widget_name]
KeyError: 'unused_treeview'

Changed in computer-janitor (Ubuntu):
importance: Medium → High
ROB3RT (rob3rt) wrote :

Happens to me too.
Ubuntu 10.04 LTS Alpha 2
If it matters, mine is 64bit. I believe that this should be moved to critical importance, because it doesn't open at all.
Any workarounds?

TM8471 (tm8471) wrote :

Happens to me too
Ubuntu 10.04 LTS Alpha 2

gissi (zerinol) wrote :

also on lucid amd64

tags: added: amd64
Benny Källström (benny-k) wrote :

Happens to me too on my laptop HP 6830s and linux kernel 2.6.33-020633rc4-generic

Changed in computer-janitor (Ubuntu):
status: Triaged → Confirmed
status: Confirmed → New

Please do not change this bug from Triaged, otherwise chances are it won't be fixed. Thank you.

Changed in computer-janitor (Ubuntu):
status: New → Triaged

Acontece toda vez que rodo o "Mantenedor do Sistema" (happens ever that I run the "System Maintainer", I think)
Estou usando (My OS) : Ubuntu 10.04 LTS - the Lucid Lynx
My PC:
Dual Core 1.6GHz
160Gb HD
2Gb RAM

Thanks!

electhor (electhor) wrote :

Happens to me on lucid lynx 64bit too!

pepness (pepness) wrote :

cada vez que intento abrir el "Encargado de Limpieza" truena.

Barry Warsaw (barry) wrote :

Here's a little more information, as it happens to me too. Note that it seems to work fine on Karmic, but crashes every time in Lucid.

So I set a pdb breakpoint in GtkUserInterface.find_and_bind_widgets(). The problem under Lucid is that o.get_property('name') always returns the empty string, which means all objects returned from builder.get_objects() get bound to the empty string in the self.widgets dictionary. Of course this means that you end up with just one entry in self.widgets, where the empty string is mapped to the last object returned from builder.get_objects(). This means of course that self.widgets['unused_treeview'] will throw the KeyError.

Interestingly enough, I traced the same method in the same branch on Karmic, and here everything succeeds. The o.get_property('name') in find_and_bind_widgets() appears to return the object names just fine, so all is hunky dory.

I don't know enough about PyGtk to provide much additional information, but it sure smells like a bug in some lower-level API. Perhaps .get_property() has been broken in Lucid? I will spend a little more time debugging this and trying to learn something about PyGtk, and will update this bug report with any additional information. I do agree though that this is a critical bug because it prevents janitor from even starting.

Barry Warsaw (barry) wrote :

Okay, a little bit more information, but sadly not enough to know what's going on.

I gdb'd the process into pygobject_get_property() in python-gobject. What appears to be happening is that the call to

g_value_init(&value, G_PARAM_SPEC_VALUE_TYPE(pspec));

is filling value with an empty string, so pyg_param_gvalue_as_pyobject() will naturally return the Python empty string object. I have no idea why g_value_init() is doing that, and gdb is not behaving well enough for me to trace into that function.

Kevin John Panzke (kevpan815) wrote :

This Bug Affects Me As Well On I386 Ubuntu 10.04 Alpha 2 As An Upgrade From Ubuntu 9.10 Gold Using Sudo Update-Manager -D.

Description: Ubuntu lucid (development branch)
Release: 10.04

computer-janitor-gtk:
  Installato: 1.14-0ubuntu1
  Candidato: 1.14-0ubuntu1
  Tabella versione:
 *** 1.14-0ubuntu1 0
        500 http://archive.ubuntu.com lucid/main Packages
        100 /var/lib/dpkg/status

Running by terminal i get:

Traceback (most recent call last):
  File "/usr/sbin/computer-janitor-gtk", line 30, in <module>
    app.run(computerjanitorapp.GtkUserInterface)
  File "/usr/share/computerjanitor/computerjanitorapp/app.py", line 101, in run
    ui.run(options, args)
  File "/usr/share/computerjanitor/computerjanitorapp/ui_gtk.py", line 211, in run
    self.create_column('unused_treeview', self.unused_filter)
  File "/usr/share/computerjanitor/computerjanitorapp/ui_gtk.py", line 291, in create_column
    treeview = self.widgets[widget_name]
KeyError: 'unused_treeview'

Barry Warsaw (barry) wrote :

mvo fixed this with the attached patch (in r218 for lp:computer-janitor). He'll upload a new version soon.

Great thank you..Everything solid so far:)  nice work!

--- On Thu, 1/21/10, Barry Warsaw <email address hidden> wrote:

From: Barry Warsaw <email address hidden>
Subject: [Bug 503727] Re: computer-janitor-gtk crashed with KeyError in create_column()
To: <email address hidden>
Date: Thursday, January 21, 2010, 9:02 AM

mvo fixed this with the attached patch (in r218 for lp:computer-
janitor).  He'll upload a new version soon.

** Attachment added: "patch.txt"
   http://launchpadlibrarian.net/38187891/patch.txt

--
computer-janitor-gtk crashed with KeyError in create_column()
https://bugs.launchpad.net/bugs/503727
You received this bug notification because you are a direct subscriber
of a duplicate bug.

Launchpad Janitor (janitor) wrote :

This bug was fixed in the package computer-janitor - 1.14.1-0ubuntu1

---------------
computer-janitor (1.14.1-0ubuntu1) lucid; urgency=low

  * computerjanitorapp/ui_gtk.py:
    - fix find_and_bind_widgets (LP: #503727)
 -- Michael Vogt <email address hidden> Thu, 21 Jan 2010 15:50:52 +0100

Changed in computer-janitor (Ubuntu):
status: Triaged → Fix Released
Tom Louwrier (tom-louwrier) wrote :

Works fine now.
Thank you!

cheers
Tom

Changed in computer-janitor (Ubuntu):
status: Fix Released → New
Barry Warsaw (barry) wrote :

Michael,

Have you tried either the new version of CJ that comes with Lucid (1.14.1-0ubuntu1) or version 2.0 which will hopefully land for beta 2, and which is available in my PPA: https://edge.launchpad.net/~barry/+archive/python

Either one should solve this problem.

Changed in computer-janitor (Ubuntu):
assignee: nobody → Barry Warsaw (barry)
milestone: none → ubuntu-10.04-beta-2
status: New → Fix Committed

This appears fixed now - running 1.14.1-0ubuntu2 in 10.04 beta 1 - Fix Released and removed assignee.

Changed in computer-janitor (Ubuntu):
assignee: Barry Warsaw (barry) → nobody
status: Fix Committed → Fix Released
Barry Warsaw (barry) wrote :

Thanks Teej. In general I don't think you need to remove the assignee when a bug gets fix released.

Changed in computer-janitor (Ubuntu):
assignee: nobody → Barry Warsaw (barry)
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers