GNOME Bugzilla – Bug 594551
commit e2fb90c118b1a2223047f6a1260c0d12db503ac2 breaks applet
Last modified: 2009-10-23 10:55:06 UTC
Hoi! Commit "Dropped verbosity, reversed local checkout check" breaks applet for me resulting in a small vertical line and nothing else being displayed in panel. Reverting fixes that problem for me. Please let me know if you need more info. Greets, Alex
At least let us know if you use the installed version (make install) or just run from the source dir.
Ah, yes, forgot that. I'm building and installing a deb-package.
Could you run it from the command line with "-w" command line switch and paste the error message if any? (You can skip any SQL commands that might come up)
(hamster-applet:8984): Bonobo-WARNING **: Can't find 'Hamster_Applet.xml' to load ui from Traceback (most recent call last):
+ Trace 217439
applet_factory(applet, None)
hamster_applet = HamsterApplet(applet)
self._gui = stuff.load_ui_file("applet.ui")
ui.add_from_file(os.path.join(runtime.data_dir, name))
-------------------------------- dpkg -L: (cut to relevant paths) /usr/lib/bonobo/servers/Hamster_Applet.server /usr/lib/pyshared/python2.5/hamster/keybinder/_keybinder.so /usr/lib/hamster-applet/hamster-applet /usr/share/gconf/schemas/hamster-applet.schemas /usr/share/gnome-control-center/keybindings/99-hamster-applet.xml /usr/share/pyshared/hamster/hamsterdbus.py /usr/share/pyshared/hamster/__init__.py /usr/share/pyshared/hamster/keybinder /usr/share/pyshared/hamster/keybinder/__init__.py /usr/share/pyshared/hamster/dispatcher.py /usr/share/pyshared/hamster/graphics.py /usr/share/pyshared/hamster/idle.py /usr/share/pyshared/hamster/about.py /usr/share/pyshared/hamster/db.py /usr/share/pyshared/hamster/storage.py /usr/share/pyshared/hamster/applet.py /usr/share/pyshared/hamster/eds.py /usr/share/pyshared/hamster/reports.py /usr/share/pyshared/hamster/stuff.py /usr/share/pyshared/hamster/preferences.py /usr/share/pyshared/hamster/edit_activity.py /usr/share/pyshared/hamster/charting.py /usr/share/pyshared/hamster/configuration.py /usr/share/pyshared/hamster/widgets.py /usr/share/pyshared/hamster/i18n.py /usr/share/pyshared/hamster/stats.py /usr/share/pyshared/hamster/defs.py /usr/share/pyshared/hamster/KeyBinder.py /usr/share/python-support/hamster-applet.public /usr/share/hamster-applet/applet.ui /usr/share/hamster-applet/preferences.ui /usr/share/hamster-applet/stats.ui /usr/share/hamster-applet/edit_activity.ui /usr/share/hamster-applet/Hamster_Applet.xml /usr/share/hamster-applet/art/stock_calendar-view-day.png /usr/share/hamster-applet/art/hamster-applet.png /usr/share/hamster-applet/art/stock_calendar-view-month.png /usr/share/hamster-applet/art/stock_calendar-view-week.png /usr/share/hamster-applet/hamster.db
I'm confused. Your traceback shows /usr/lib/pymodules/python2.5 while dkg says /usr/share/pyshared. Please double-check your installation.
Sorry, I'm afraid I don't get what you mean. The package is being built using "dpkg-buildpackage", with no additional steps done by myself. The files are indeed installed into "/usr/share/pyshared" and with the changes done by the commit mentioned above I get exactly that traceback.
I'm guessing that whatever distro you are running is configuring hamster to use /usr/lib/pymodules/python2.5 and then either patches the installer or forcibly moves the files to /usr/share/hamster-applet/. This is incorrect and causes the installation detection code to fail (it expects the path it was configured with and finds something completely different and thus assumes you run hamster uninstalled). Please fix your distro to either not move files to /usr/share or fix the patch to also correct PYTHONDIR in defs.py.
Thank you for the input so far Alex! Could it be that you are building the package using hamster's debian/ folder? That stuff is totally outdated and building is now in the hands of the distributions themselves. I've removed the /debian folder in git head now. Please let us know if that was what you were doing. The recommended way of building hamster from sources is autogen -> make -> make install (described in http://projecthamster.wordpress.com/building-and-running/)
I'm indeed using the debian/ folder but the one used by Debian in version 2.26.2-1. I appreciate the removal in HEAD though ;-). No patches applied or install files moving to other directions, btw.
Ah, i'm lost now. Will the debian be fine or do we need to report a bug to them?
Alex: Please find the cause of python thinking the code sits in /usr/lib/pymodules/python2.5 while the files are in /usr/share and we can work on a fix from there. Please note I'm not yet convinced the fix should go to hamster and your distro.
Found a bug in current git (or rather an uncommited change on my part). Sorry for the inconvenience, should be fixed now in master.
Created attachment 145674 [details] [review] Debian's patch
IMHO the bug has not been fixed for "building" in Debian. See above patch the use for 2.28. Sorry for the noise, thought it might interest you.
Review of attachment 145674 [details] [review]: the patch removes ability to run applet uninstalled, which is necessary for efficient development
*** Bug 599352 has been marked as a duplicate of this bug. ***
Perhaps the check could be inverted, running with defs.DATA_DIR unless ../data/ exists, or a variant?
Perhaps distros shouldn't move files after installation? hamster/Makefile.am says that Hamster is installed to PYEXECDIR and so does hamster/defs.py.in If you absolutely need to move Hamster to another location (despite it shipping an elf binary in _keybinder.so), patch both locations. If you break this consistency then you could as well delete half of the files and complain about the applet not being usable.