August 16, 2011, 19:53:59 Last Edit: August 20, 2011, 13:38:38 by Bestia
I'm using gmusicbrowser for a very long time and it doesn't make problems mostly. Unfortunately when I started it today the only thing I saw was a window without all the widgets and it didn't played music. I've checked in gnome-system-monitor that it uses about 100% of my CPU.

I'm on Ubuntu 11.04 with Unity and I'm using the gmusicbrowser daily build PPA ( from Andreas Boettger) also the gmusicbrowser art PPA. The last update was about three days ago but gmusicbrowser worked fine yesterday. I've tried installing the older version from that PPA (1.1.7+808) but it didn't solve the issue. I've also made package from git and still no success.

This is what I get when running it from terminal:

print() on closed filehandle $fifofh at /usr/bin/gmusicbrowser line 288.
Reading saved tags in /home/mateusz/.config/gmusicbrowser/gmbrc ...
Reading saved tags in /home/mateusz/.config/gmusicbrowser/gmbrc ... done
playing /media/Muzyka/Play/Gustaf Tivander - Sanctum Soundtrack (2011)/01 - Skye's Theme.flac


I have also tried to attach the result of the debug and backtrace commands to no avail, so instead here are fragments of the output:

Use of uninitialized value $HomeDir in concatenation (.) or string at /usr/bin/gmusicbrowser line 265.
at /usr/bin/gmusicbrowser line 265
main::BEGIN() called at /usr/bin/gmusicbrowser line 314
eval {...} called at /usr/bin/gmusicbrowser line 314
using '' folder for saving/setting folder instead of '/home/mateusz/.config/gmusicbrowser/'
at /usr/bin/gmusicbrowser line 265
main::BEGIN() called at /usr/bin/gmusicbrowser line 314
eval {...} called at /usr/bin/gmusicbrowser line 314
print() on closed filehandle $fifofh at /usr/bin/gmusicbrowser line 288.
at /usr/bin/gmusicbrowser line 288
main::BEGIN() called at /usr/bin/gmusicbrowser line 314
eval {...} called at /usr/bin/gmusicbrowser line 314
oggheader.pm : using Digest::CRC
at /usr/bin/../share/gmusicbrowser/oggheader.pm line 30
eval {...} called at /usr/bin/../share/gmusicbrowser/oggheader.pm line 28
Tag::OGG::INIT() called at /usr/lib/perl5/Digest/CRC.pm line 0
eval {...} called at /usr/lib/perl5/Digest/CRC.pm line 0
Reading plugin /usr/bin/../share/gmusicbrowser/plugins/artistinfo.pm
at /usr/bin/gmusicbrowser line 1499


main::CreateTrayIcon() called at /usr/bin/gmusicbrowser line 1278
HasChanged Sort -> updating CODE(0xa3f8718) GMB::DBus::MPRIS2=HASH(0xb19b248) Layout::Button=HASH(0xbc37730)
at /usr/bin/gmusicbrowser line 6611
main::HasChanged('Sort') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('1_HasChanged_Sort') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
HasChanged Filter -> updating Layout::Button=HASH(0xb19c0b0) Layout::Label=HASH(0xb19ea10)
at /usr/bin/gmusicbrowser line 6611
main::HasChanged('Filter') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('1_HasChanged_Filter') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
Next file to play : /media/Muzyka/Play/Gustaf Tivander - Sanctum Soundtrack (2011)/02 - Below.flac
at /usr/bin/gmusicbrowser line 2566
main::PrepNextSongs() called at /usr/bin/gmusicbrowser line 2918
main::DoTask('2_PrepNextSongs') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
HasChanged NextSongs -> updating CODE(0xa364c88)
at /usr/bin/gmusicbrowser line 6611
main::HasChanged('NextSongs') called at /usr/bin/gmusicbrowser line 2567
main::PrepNextSongs() called at /usr/bin/gmusicbrowser line 2918
main::DoTask('2_PrepNextSongs') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
HasChanged Pos -> updating CODE(0xa3f8718) Layout::Label=HASH(0xb19ea10)
at /usr/bin/gmusicbrowser line 6611
main::HasChanged('Pos', 'song') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('1_HasChanged_Pos') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
filling FilterList=HASH(0xbc37e90)
at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 2428
FilterList::Fill('FilterList=HASH(0xbc37e90)') called at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 1997
FilterPane::refresh_current_page('FilterPane=HASH(0xb19e8c0)') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('9_FPFilterPane=HASH(0xb19e8c0)') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
filling FilterList=HASH(0xb280a80)
at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 2428
FilterList::Fill('FilterList=HASH(0xb280a80)') called at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 1997
FilterPane::refresh_current_page('FilterPane=HASH(0xb19c080)') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('9_FPFilterPane=HASH(0xb19c080)') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284
filling FolderList=HASH(0xb12fae8)
at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 2545
FolderList::Fill('FolderList=HASH(0xb12fae8)') called at /usr/bin/../share/gmusicbrowser/gmusicbrowser_list.pm line 1997
FilterPane::refresh_current_page('FilterPane=HASH(0xb0ce318)') called at /usr/bin/gmusicbrowser line 2918
main::DoTask('9_FPFilterPane=HASH(0xb0ce318)') called at /usr/bin/gmusicbrowser line 1284
eval {...} called at /usr/bin/gmusicbrowser line 1284


that's the beginning and the end of it.

I don't know what could be the cause of this.
Two things you can try :
1) try running it with the option "-l minimal", that will start gmb with the layout "minimal".
2) maybe try changing the gtk theme ?

Let me know what is the result.

Running gmusibrowser in minimal mode gives me the exact same result. I also tried changing the gtk theme yesterday.

Here you will find the full output of debug and backtrace:

http://pastebin.com/HgvQ5bTY

Can you try with the latest commit (http://git.gmusicbrowser.org/commit/f163044716) ? It will print a stack trace when interrupted with ctrl-c so we should have an idea of what it is doing with the 100% cpu. If that is not enough we'll move to tracing the whole code.

if you don't want to run the git version, you can simply add the 2 lines anywhere at the top of the gmusicbrowser.pl (installed as /usr/bin/gmusicbrowser)

I have tried it both ways (git and adding the two lines) and unfortunately when I press ctrl-c it doesn't quit. I've also tried with ctrl-d nothing happens and then ctrl-\ this closes gmusibrowser and terminal so I don't get anything. It's strange that ctrl-c doesn't work as should. I'm using that shortcut for quitting games running with Wine.

I've kind workaround my problem by moving all of my gmbrc files to trash. Than I could start gmusicbrowser add my folders to the collection, make new playlists and finally play my music.

Sorry I didn't reply sooner.
I don't know if you kept the gmbrc file and if you are still willing to help me find the issue, but if you are :

I really don't know why ctrl-c doesn't work, that's very strange, I use it all the time with gmb. You can try sending the signal with the command kill by finding the process ID, with for example "top" and doing "kill -2 PROCESS_ID", though I really don't know if this will make a difference.

I've found a way to get a full trace of the execution, download the file http://gmusicbrowser.org/files/SimpleTrace.pm and follow the instructions at the top of the file if you want to give it a try.

Feel free to ignore this if you can't reproduce the problem anymore, and/or don't want to bother.