Bug 207 - Randomized-by-album playlist always starts with same album
: Randomized-by-album playlist always starts with same album
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Audio
: unspecified
: PC Debian Linux
: P4 minor (vote)
: ---
Assigned To: Blackketter Dean
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2004-03-05 20:50 UTC by Amy!
Modified: 2008-09-15 14:37 UTC (History)
2 users (show)

See Also:
Category: ---


Attachments
don't go to track current song when loading a playlist shuffled. (1.34 KB, patch)
2004-09-20 18:56 UTC, KDF
Details | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Amy! 2004-03-05 20:50:16 UTC
I use my squeezebox as a sort of personal radio station: set the playlist to be
all albums, and randomize by album.  Whenever I add new music (or finish a cycle
and notice it, but that takes two weeks), I clear the playlist, rescan, and add
"all songs" from "browse by album".  The playlist created *always* starts with
the same album.  I prolly wouldn't mind, but it's one I don't like that much.  I
can't find a configuration option to change the starting album (or starting
song), or any other way to control this.  The workaround is to click on
whatever-the-first-song-in-the-next-album-is (*that* album is always different),
then click albums (to randomize again).  But it's rather irritating.  If I have
to always start with the same album, could I at least pick the album?  Thanks.
Comment 1 Jason Holtzapple 2004-09-15 16:38:26 UTC
*** Bug 558 has been marked as a duplicate of this bug. ***
Comment 2 KDF 2004-09-20 11:50:46 UTC
seems to be by design. The reshuffle algorithm keeps track of the current song,
and keeps that at the start, thus if you save a playlist, it will always start
with the current song or the current album on which the current song resides. 
When saing a playlist from slimserver, it does store the current song in the
EXTINF tags.  

One solution is to have the reshuffle ignore the current song when loading a
playlist, editing line 792 of Command.pm like so:
Slim::Player::Playlist::reshuffle($client,1);

-kdf
Comment 3 KDF 2004-09-20 12:40:52 UTC
oh and, of course, the suffle routine for album has to actually obey this.  line
338 of Playlist.pm needs to be:
if ($realsong == -1 && !$dontpreservecurrsong) {

however, I'm certain that if $realsoong == -1 that ist shoudn't do anything
anyway, so that whole if statement can probably go.

what might be problematic here is if some users WANT the current song to persist
from teh last time they played a particular playlist.  But, this really requires
resaving thw playlist, or a way to keep track of the most recent current song. 
That, however, is part of another bug report.
Comment 4 KDF 2004-09-20 18:56:46 UTC
Created attachment 133 [details]
don't go to track current song when loading a playlist shuffled.

dontpreservecurrsong, if set and respected when loading the playlist will avoid
causing the same album every time.
Comment 5 Chris Owens 2006-06-16 14:41:52 UTC
There are 536 bugs in the database with targets of '---' that were fixed prior to new year 2006.  I am setting them to targets of 6.2.1 to keep them from showing up in my queries.