Bug 1212 - Adding item to playlist does not update properly
: Adding item to playlist does not update properly
Status: RESOLVED FIXED
Product: Logitech Media Server
Classification: Unclassified
Component: Web Interface
: 6.0.0
: All All
: P1 major (vote)
: ---
Assigned To: Dan Sully
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2005-03-27 07:04 UTC by Jacob Potter
Modified: 2008-08-18 10:54 UTC (History)
0 users

See Also:
Category: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jacob Potter 2005-03-27 07:04:46 UTC
Status.xml doesn't properly output the playlist when adding a song with the
"p0=playlist&p1=add" syntax. The problem does not seem to occur during normal
use of any of the skins except ExBrowse2/Default2.

Within ExBrowse2, adding a single song causes the playlist count to update
correctly, but the actual list does not update until the next refresh. This can
be up to 5 seconds later. Both the add and the subsequent refresh use
status.xml, not status_header or playlist. I've confirmed that slimserver does
generate a status.xml with the correct "songcount" parameter but an incorrect
playlist, so it's not just a Javascript issue.

This only occurs with "p0=playlist&p1=add&p1=[% itempath %]". Using
"command=playlist&subcommand=addtracks&track=[% item %]" works perfectly within
ExBrowse2, so I could use that as a workaround for 6.0.0. Is there a better way
of adding a single song by id?

I'm guessing that this has something to do with svn 2528, keeping a pre-rendered
cache of the now playing list on the server.
Comment 1 Dan Sully 2005-03-27 14:57:25 UTC
I can't actually find anywhere that 'add' is recognized as a valid command.

Go ahead with the workaround for now.
Comment 2 Jacob Potter 2005-03-27 15:17:19 UTC
I thought it was a synonym for "append". I'll check if using append fixes it.
Comment 3 Jacob Potter 2005-03-27 16:08:35 UTC
Nope, still broken with "append". Workaround coming for 6.0.0.
Comment 4 Dan Sully 2005-03-27 16:27:08 UTC
Heya - we're trying to get 6.0 out tonight.. think you'll have a fix soon? :)
Comment 5 Jacob Potter 2005-03-27 16:29:39 UTC
I'm working on it now, maybe an hour or so?
Comment 6 Dan Sully 2005-03-30 16:32:03 UTC
Jacob - I just took a look at this. Sending "playlist add itempath" on the CLI
works fine. I notice a typo in your bug report - with p1=itempath - if that was
the case in the code, it should really be p2
Comment 7 Jacob Potter 2005-03-30 16:48:00 UTC
Typo in the bug report. I just checked svn and it was using p2=.

Fooey.

Does the CLI method report the new playlist immediately, or are you using an
additional command to check it?
Comment 8 Dan Sully 2005-03-30 16:58:05 UTC
The CLI reports it immediately - and if I look at softsqueeze, it's been updated.
Comment 9 Dan Sully 2005-04-07 16:47:08 UTC
Jacob - have you had time to look at this?

I'm going to assign it to you for now.. trying to get my bug list in manageable
shape.

Please reassign back if this is a real issue.

Thanks.
Comment 10 Jacob Potter 2005-04-07 17:48:26 UTC
I'll look at it some more. It's not affecting anything at the moment, since I
switched all my skins to use addtracks/loadtracks instead.
Comment 11 Jacob Potter 2005-04-18 18:06:02 UTC
Here's a new issue, but they seem to be related, so I'll put it here. Thanks to
dbls for noticing this.

Switching skins via the settings page causes the old playlist template to be
partially used. The wrapper (playlist.html) is correct, but the items themselves
(status_list.html) are not properly regenerated. When the list is modified, each
item outputs correctly.

This happens across all skins, although not when they are accessed explicitly
with /SkinName/.

Back to you, Dan...
Comment 12 KDF 2005-04-19 12:38:33 UTC
could you please confirm this skin problem with the latest nightly?  I noticed
this a while back and put in a fix to reset the playlist cache when skin is
changed.  Remember, just changing the skin setting is never valid, you must
still click the "click here to refresh" link, since changing the setting does
not have any way to tell teh browser to reload.
Comment 13 Blackketter Dean 2005-04-20 14:39:12 UTC
Jacob:  can you open a new bug with the info in comment 11?  The other issue appears to be resolved.  
Thanks.