Red Hat Bugzilla – Bug 799906
Can't load XSPF playlist in amarok
Last modified: 2012-05-19 02:55:26 EDT
Created attachment 567578 [details]
Example XSPF playlist that won't load in amarok
Description of problem:
I have an XSPF playlist that I'm unable to load in the latest version of Amarok (2.5.0-3). The playlist is correctly detected when I run "Update Collection" and appears under Media Sources Home->Playlists->Saved Playlists->Playlist Files on Disk. However, none of the tracks are actually shown when I try to expand the playlist, and I'm unable to move it to the main playlist frame.
All the tracks are streams (from di.fm). A pls playlist with the same tracks works fine. I have a similar problem if I try to load the playlist directly using Playlist->Add Media, however, the listed streams load fine if I enter the stream addresses directly using Playlist->Add Stream.
I can confirm the problem on three seaparate systems running Fedora 16 (not all mine).
Version-Release number of selected component (if applicable):
(Also tested on binary built from 2.5-git source)
Steps to Reproduce:
1. Add the playlist to the collection
2. Go to Media Sources Home->Playlists->Saved Playlists->Playlist Files on Disk
3. Select the playlist and try dragging it to the main playlist
Alternatively, select the playlist through Playlist->Add Media.
The tracks listed in the playlist should appear in the main playlist.
I've attached a minimal playlist which demonstrates the problem.
I also filed this bug with upstream but they can't confirm it: https://bugs.kde.org/show_bug.cgi?id=295199
After some looking at the 2.5/2.5-git source code I tracked my problem to the file src/core-impl/playlists/types/file/xspf/XSPFPlaylist.cpp and the triggerTrackLoad() method. The problem seems to be in the code block at line 259:
if( trackPtr )
* NOTE: If this is a MetaProxy::Track, it probably isn't playable yet,
* but that's okay. However, it's not a good idea to get another
* one from the same provider, since the proxy probably means that
* making one involves quite a bit of work.
* - Andy Coder <email@example.com>
if( !trackPtr->isPlayable() && ( typeid( * trackPtr.data() ) != typeid( MetaProxy::Track ) ) )
trackPtr = CollectionManager::instance()->trackForUrl( track.identifier );
Coming into this block, trackPtr is non-null and "if (trackPtr)" succeeds, as does the second "if", triggering an update to trackPtr. When it leaves this block, trackPtr is null. If I comment out the "trackPtr = collectionManager..." line, the streams load and play fine.
I don't know exactly what's going on here and why this is a problem for me but not for upstream. I'm hoping someone else can confirm the problem.
Created attachment 567579 [details]
Example PLS playlist with identical track that will load
I can reproduce on f17 too. interesting.
amarok-2.5.0-8.fc16 has been submitted as an update for Fedora 16.
* should fix your issue,
* was pushed to the Fedora 16 testing repository,
* should be available at your local mirror within two days.
Update it with:
# su -c 'yum update --enablerepo=updates-testing amarok-2.5.0-8.fc16'
as soon as you are able to.
Please go to the following url:
then log in and leave karma (feedback).
amarok-2.5.0-8.fc16 has been pushed to the Fedora 16 stable repository. If problems still persist, please make note of it in this bug report.