Bug 2657 - Empty album title in slimserver.log and trackinfo structure.
: Empty album title in slimserver.log and trackinfo structure.
Status: RESOLVED INVALID
Product: Logitech Media Server
Classification: Unclassified
Component: Plugins
: 6.2.1
: PC RedHat Linux
: P3 normal (vote)
: ---
Assigned To: Dan Sully
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-11-29 14:33 UTC by Tom Simonsen
Modified: 2008-09-15 14:39 UTC (History)
1 user (show)

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Tom Simonsen 2005-11-29 14:33:57 UTC
I was testing the NowPlaying plugin that Max Spicer is developing. During this testing I found out that the Album title sometimes was empty. Looking at the slimserver log, it was empty there too!

After some more testing I found out what causes it. I stopped and started the slimserver daemon while my squeezebox was playing...

To reproduce (I am using scientificlinux 4 - a RHEL4 clone:
On squezeebox: Create a new playlist, and start playing.
as root: service slimserver restart
wait till squeezebox shuts up.
On squeezebox, select a song using the arrow keys and press play.
Look at the log (my example...)
2005-11-29 23:20:45.4495 NowPlaying: newsong cmd received
2005-11-29 23:20:45.4550 NowPlaying: Current song: Here Comes The Night by Janis Ian from Night

<restart>2005-11-29 23:24:06.9764 NowPlaying: newsong cmd received
2005-11-29 23:24:06.9837 NowPlaying: Current song: Here Comes The Night by Janis Ian from
Comment 1 KDF 2005-11-29 14:43:46 UTC
max, can you verify that this is a slimserver problem and not a plugin problem?
Comment 2 Dan Sully 2005-11-29 17:16:58 UTC
Tom - does this still occur if the Plugin isn't installed?
Comment 3 Tom Simonsen 2005-11-30 00:33:29 UTC
(In reply to comment #2)
> Tom - does this still occur if the Plugin isn't installed?
> 
I will test when I come home from work
Comment 4 Tom Simonsen 2005-11-30 08:57:04 UTC
The log output I saw is from the plugin, so if I remove the plugin, I can't test it!

The code in question looks OK:

my $trackInfo = Slim::Player::Playlist::song($client);
$track .= " from " . $trackInfo->{'album'}->{'title'};

I have done some more testing and I can't always reproduce the error. Today it has been working OK...
Comment 5 Dan Sully 2005-11-30 09:54:41 UTC
Well - Max is breaking encapsulation there..

That should be something like:

my $trackObj = Slim::Player::Playlist::song($client);

$track .= " from " . $trackObj->album->title;
Comment 6 Tom Simonsen 2005-11-30 10:44:16 UTC
Aaaah. 

I am a bit rusty on perl OO programming, so I didn't catch that.

I have updated my copy of the plugin to use the correct syntax.

What I don't understand is that I could repeatedly reproduce the problem yesterday, but I can't make it break today!
Comment 7 Max Spicer 2005-11-30 10:53:45 UTC
Whoops, sorry about that!  I'll get my plugin sorted.