preview_menu incorrectly set to None instead of TextMenu

Bug #253285 reported by Matt Layman on 2008-07-30
Affects Status Importance Assigned to Milestone
Entertainer Media Center
Matt Layman

Bug Description

I've been meaning to try out Entertainer since I saw an article about it on I tried it back then, but since I'm using gentoo and the portage overlay which had clutter and pyclutter had 0.4 versions (and I didn't have enough time at the moment to manually go through the dependency hell ;p), I stalled it.

Recently I made myself some time to try it out. I'm currently using these dependencies' versions:


The reason for the newer versions is that before I tried it with these dependencies' versions:

clutter-core 0.5.6 (as 0.5.4 is not in the clutter-project server)
clutter-gst 0.5.0
clutter-gtk 0.5.2
clutter-cairo 0.5.0

But I had the same problem in both setups: Entertainer starts and indexes fine (I checked it the-gentoo-way: opened the .db files and looked in the thumbnails directory: both show signs of content being indexed). However, when opening the frontend, I don't see any content in any of the sections. Neither the logs nor the program output in the terminal show any sign of errors.

When trying to enter the sections, this exception occurs (which I guess is obviously due to an empty list):

Traceback (most recent call last):
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/", line 443, in handle_keyboard_event
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/", line 524, in handle_user_event
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/screens/", line 339, in handle_user_event
AttributeError: 'NoneType' object has no attribute 'set_active'

Of course what should happen is that I should see some content =P.

Any hints as to what I may try for further debugging, or if I'm missing something/doing something wrong? I'm open to suggestions.

Needless to say, this is the best looking media center for Linux that is currently out there. A shame I couldn't try it yet, but keep up your excellent work folks :).


Matt Layman (mblayman) wrote :

GODLiKE, from the Traceback, it appears that preview_menu is wrong. I checked the and saw the line of code "self.preview_menu = menu". menu should be a TextMenu widget. Could you try adding "print self.preview_menu" after the variable assignment line? If the TextMenu is not returning a valid object, we can at least narrow down the scope of this problem.

If I had to guess about what this problem is before we do any in depth analysis on it, I would guess that this will boil down to a problem with the clutter installation on your machine. But I can certainly work with you to resolve this because it may actually be a bug in Entertainer, and that's obviously what we want to find out.

Changed in entertainer:
importance: Undecided → Medium
status: New → Incomplete

(I didn't see this bug before and I opened a new one, please close it: sorry :$)

Matt, I added the line you mentioned and noticed that it is inside def show_rss_preview(self):

So when I navigate to the rss headline menu item, I get this output:

<TextMenu object at 0xa7355a4 (ClutterGroup at 0xa504320)>

(BTW, headlines menu is the one thing that always worked)

The previous traceback was triggered if I entered any menu by pressing left when standing on it. Now upon entering the photographs menu (by pressing enter) I get a warning about not having any content, and when trying to navigate, this traceback:

Traceback (most recent call last):
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/", line 439, in handle_keyboard_event
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/", line 518, in handle_user_event
  File "/home/godlike/sandbox/bzr/entertainer/entertainerlib/frontend/gui/screens/", line 410, in handle_user_event
AttributeError: 'PhotoAlbumsScreen' object has no attribute 'menu'


If I try to enter the Video menu, I get the three sections on top, and on each a similar warning about not having any content (no tracebacks here). If I try to enter it having previously entered a directory in "Video" to get it indexed, and waiting for it to be completely indexed, Entertainer crashes (no traceback though, simply closes itself).

Matt Layman (mblayman) wrote :

GODLiKE, that's quite interesting. I had noticed the traceback from the main menu when I hit the left arrow, but I hadn't taken the time to report it. Could that possibly be the root of your problems? If you don't use the left arrow, then enter the other menus, do you still get the errors that you're reporting. Maybe the left arrow is affecting some menu state in a weird way.

Paul, in answer to your question on the now invalid bug that GODLiKE created, I have not encountered any of this weirdness during my UI refactoring, but the scope of that refactoring has focused on resolution indpendence. I'm wondering if the problem stems from not handling all user events properly. A lot of screens have custom user handling if statements. I think that the entire system for handling user events could be refactored to prevent weird errors from random key strokes. If we come up with some more generic way to handle events, we might be able to control spurious key presses. For example, none of the user event if/elif blocks have else statements to handle events that are not explicitly stated. This is obviously not good because we don't really have a clue as to what the system will do with those unhandled events.

I get no tracebacks when entering the menus with the enter key, although If I have any content to be indexed for a specific section, then when trying to enter that section, Entertainer crashes. Sometimes there is no error message, sometimes I get a message like this on the console:

0f8fa233-999e-ce97-50e6ae20-05435870 is dumped

Of course different each time, but I guess that was the gnome bug reporting tool (because it appeared on those times. BTW there was no useful information on the bug report, otherwise I would post it here).

Sorry, that was myself talking out loud :P. Back to the problem, when indexing any content for a specific section, I can no longer enter that section. With the exception of the music section which I can never enter having indexed some content or not.

There is no traceback in any of the crashes =/. What keeps puzzling me is that the .db files show content, and there're images in the thumbnail directory.

I would think that this is just a temporal quirk product of using a live src version that would eventually get fixed, but I also experienced this with the 0.1 version.

Matt Layman (mblayman) wrote :

GODLiKE, I now have a couple more months of experience from looking at the user interface code than when I first answered this question. I believe the preview menu is not created until you go down to the headlines option. By hitting the left arrow key, I believe that you are attempting to access the menu before it even exists.

This issue is totally separate from your display problem of indexed content not displaying and crashing Entertainer. Can you check the trunk again to see if this is still a problem for you on Gentoo? If so, could you please file it in a new bug so we can capture the two different issues and track them separately.

Changed in entertainer:
assignee: nobody → laymansterms
status: Incomplete → Triaged
Matt Layman (mblayman) wrote :

Josh managed to fix this when he was working his fix feeds branch for the other 0.2 milestone feed bugs.

Changed in entertainer:
status: Triaged → Fix Committed
Paul Hummer (rockstar) on 2008-10-09
Changed in entertainer:
status: Fix Committed → Fix Released

Thanks Matt. Haven't been around due to college/work stuff (and also because the email I submitted here is an old account that I don't normally check :P). I've formatted a new machine for myself and am currently installing Gentoo amd64. Will surely try Entertainer out these days as soon as I make myself a hole :).

Thanks again, hope Entertainer becomes the default media center in many distros ;)!

To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers

Related questions