Bug 189328 - amarok forgets that it has downloaded podcast episodes
Summary: amarok forgets that it has downloaded podcast episodes
Alias: None
Product: amarok
Classification: Unclassified
Component: Podcast (show other bugs)
Version: 2.1-SVN
Platform: unspecified Linux
: NOR normal (vote)
Target Milestone: ---
Assignee: Amarok Developers
Depends on:
Reported: 2009-04-11 00:37 UTC by Mathias Panzenböck
Modified: 2009-04-13 15:30 UTC (History)
1 user (show)

See Also:
Latest Commit:
Version Fixed In:


Note You need to log in before you can comment on or make changes to this bug.
Description Mathias Panzenböck 2009-04-11 00:37:29 UTC
Version:           2.1-SVN (using 4.2.2 (KDE 4.2.2), 4.2.2-1.fc10 Fedora)
Compiler:          gcc
OS:                Linux (x86_64) release

When you download a podcast episode using amarok, the next time you start it it has forgotten that the episode was downloaded. When you drag the episode into the playlist the http url gets streamed. However, if you drag the episode into the playlist immediately you've downloaded it, amarok will use a file://... path (instead of /...). This for some reason causes that it thinks its a remote file and no tags are loaded/shown.

PS: I'm almost certain that I've reported this before, but I could not find my older report.
Comment 1 Bart Cerneels 2009-04-12 10:51:04 UTC
I've investigated this and it seems the podcast episode remembers it's playableUrl just fine, but it is not loaded when restoring the session on startup.
I think we need to implement Collection::trackForUrl on the SqlPodcastProvider to make this work.
Comment 2 Bart Cerneels 2009-04-12 12:38:17 UTC
SVN commit 952617 by shanachie:

Implement TrackProvider::trackForUrl in SqlPodcastProvider and make sure it's registered with CollectionManager before restoring The Playlist.

 M  +5 -0      playlist/PlaylistModel.cpp  
 M  +23 -3     podcasts/sql/SqlPodcastProvider.cpp  

WebSVN link: http://websvn.kde.org/?view=rev&revision=952617
Comment 3 Mathias Panzenböck 2009-04-12 13:39:23 UTC
What am I making wrong, when I do svn up I get:
$ svn up
At revision 951942.

Which is obviously older than 952617.
Comment 4 Mark Kretschmann 2009-04-12 13:45:21 UTC
@Mathias: KDE's AnonSVN servers are currently out-of-sync, and the admins are on holidays or something. Workaround: Check out via websvn, like this:

"svn co svn://websvn.kde.org:443/home/kde/blah...."

You will have to make a completely new checkout for this, you can't just svn update.
Comment 5 Mathias Panzenböck 2009-04-12 15:46:17 UTC
@Mark: Thanks! However, I still get the http:// urls when dragging the episodes in the playlist. Do I have to delete the old subscriptions and subscribe again? I don't want to click "Remove Subscriptions" because in Amarok 1 this delete all podcast episodes (instead of removing the subscription only).

I use custom locations to save the episodes to, but back when I used the default location the behaviour was the same.
Comment 6 Bart Cerneels 2009-04-12 16:51:23 UTC
> However, I still get the http:// urls when dragging the episodes
in the playlist.
That should not happen. Are you sure those episodes have finished downloading before you drag them?
Comment 7 Mathias Panzenböck 2009-04-12 17:43:34 UTC
Yes I am sure. E.g. there is the episode: http://chaosradio.ccc.de/archive/chaosradio_144.mp3
I downloaded it using amarok and now this local file exists: /home/panzi/audio/chaos-podcast/chaosradio_144.mp3
And the configured destination directory for the podcast episodes is: /home/panzi/audio/chaos-podcast
The feed url is: http://chaosradio.cc…haosradio-latest.rss
Erm, ok there is the next bug when copying the feed url. Here the real url is: http://chaosradio.ccc.de/chaosradio_express-latest.rss
The only other podcast I have currently subscribed (and shows the same behaviour) is: http://chaosradio.ccc.de/chaosradio-latest.rss
Comment 8 Mathias Panzenböck 2009-04-13 15:30:34 UTC
I redownloaded one episode just to see if that changes anything. It does. Newly downloaded episodes seem to be remembered. However, they still get the file:// prefix, which causes amarok to think it's a stream and you cannot read or even edit the id3 tags. Pity that the old episodes aren't detected as downloaded. Amarok should scan the target folder of the podcast feed in order to detect whether episodes are already downloaded (maybe downloaded with another program or an former amarok installation where the database got lost).