After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 355984 - Atom podcast support
Atom podcast support
Status: RESOLVED FIXED
Product: rhythmbox
Classification: Other
Component: Podcast
HEAD
Other Linux
: Normal enhancement
: ---
Assigned To: RhythmBox Maintainers
RhythmBox Maintainers
: 438538 438650 (view as bug list)
Depends on: 484768
Blocks:
 
 
Reported: 2006-09-14 16:35 UTC by Tim Retout
Modified: 2008-01-07 12:08 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Atom support using the current feed parsing system (11.06 KB, patch)
2006-09-14 16:39 UTC, Tim Retout
none Details | Review
Atom support, removed timezone parsing. (11.05 KB, patch)
2006-09-14 22:16 UTC, Tim Retout
none Details | Review
Adds backwards compatibility for usage of totem-plparser. (3.80 KB, patch)
2008-01-04 14:13 UTC, Kern Handa
rejected Details | Review

Description Tim Retout 2006-09-14 16:35:11 UTC
Currently only RSS podcast feeds are supported; there are some which use Atom.

Test feeds:

 * http://planet.lugradio.org/hashlugradio/releases/episodes/feed/atom/ (Atom 0.3)
 * http://ccmixter.org/media/feed/atom/audio (Atom 1.0)
Comment 1 Tim Retout 2006-09-14 16:39:04 UTC
Created attachment 72796 [details] [review]
Atom support using the current feed parsing system

This hacks Atom support into the current SAX parser. It's not been thoroughly tested; it might well not support every Atom feed out there.

An alternative approach is to fix bug #323057.
Comment 2 Alex Lancaster 2006-09-14 18:26:39 UTC
(In reply to comment #1)

> An alternative approach is to fix bug #323057.

I think podcasting could/may be will become pluginised before rewriting the parsing engine.  Jonathan Matthew did say something about redoing that, but it may happen later (there maybe a bug about it somewhere too).
Comment 3 Tim Retout 2006-09-14 22:16:17 UTC
Created attachment 72818 [details] [review]
Atom support, removed timezone parsing.

It seems that trying to parse the timezone of an Atom feed with GNU strptime's '%z' is pointless, because:

 1. It breaks dates that end in 'Z', which is valid for UTC times.
 2. strptime ignores it anyway, and doesn't change the tm struct.
Comment 4 Reuben 2006-10-09 23:49:27 UTC
Not sure if this issue with Atom podcasts is already addressed, but it should be noted that Atom podcast episodes can have multiple enclosures. (This allows for things like haveing a podcast in multiple formats all within the same feed)
Comment 5 John Russell 2007-04-18 19:42:32 UTC
Since people fix things because they want it to work I thought I'd add some motivation here.  Google reader allows you to subscribe to any of your folders or labels as an atom feed.  So from your gazillion podcasts, you can browse in Reader and label the individual episodes you actually want to listen to as "ipod" or "listen" or whatever.  Then have RB subscribe to that one atom feed and drag it over to your ipod.  

How cool would that be?  

Yeah, yeah, I know. Go learn C.  Just thought I'd try.
Comment 6 James "Doc" Livingston 2007-05-15 10:32:33 UTC
*** Bug 438538 has been marked as a duplicate of this bug. ***
Comment 7 Jonathan Matthew 2007-06-30 09:40:34 UTC
*** Bug 438650 has been marked as a duplicate of this bug. ***
Comment 8 Bastien Nocera 2007-10-24 16:16:41 UTC
(In reply to comment #0)
> Currently only RSS podcast feeds are supported; there are some which use Atom.
> 
> Test feeds:
> 
>  * http://planet.lugradio.org/hashlugradio/releases/episodes/feed/atom/ (Atom
> 0.3)
>  * http://ccmixter.org/media/feed/atom/audio (Atom 1.0)

the CCmixter one doesn't work anymore. Both seem to be parsed correctly by Totem's playlist parser.
Comment 9 Bastien Nocera 2007-10-24 16:20:20 UTC
(In reply to comment #8)
> (In reply to comment #0)
> > Currently only RSS podcast feeds are supported; there are some which use Atom.
> > 
> > Test feeds:
> > 
> >  * http://planet.lugradio.org/hashlugradio/releases/episodes/feed/atom/ (Atom
> > 0.3)
> >  * http://ccmixter.org/media/feed/atom/audio (Atom 1.0)
> 
> the CCmixter one doesn't work anymore. Both seem to be parsed correctly by
> Totem's playlist parser.

Never mind, working again :)
Comment 10 Bastien Nocera 2007-10-25 10:03:32 UTC
The patch in bug 484768 should fix it.
Comment 11 Bastien Nocera 2007-12-03 13:16:45 UTC
2007-12-03  Bastien Nocera  <hadess@hadess.net>

        * configure.ac: Require totem-pl-parser 2.21.4

        * lib/rb-file-helpers.c: (rb_uri_could_be_podcast):
        * lib/rb-file-helpers.h: Add helper function to detect
        whether it could be a podcast from the URI passed

        * data/rhythmbox.schemas: Handle feed://, itpc:// and itms:// URIs

        * podcast/Makefile.am:
        * podcast/rb-podcast-manager.c:
        (rb_podcast_manager_subscribe_feed),
        (rb_podcast_manager_parse_complete_cb),
        (rb_podcast_manager_thread_parse_feed),
        (rb_podcast_manager_save_metadata),
        (rb_podcast_manager_insert_feed):
        * podcast/rb-podcast-parse.c: (playlist_metadata_foreach),
        (playlist_started), (playlist_ended), (entry_metadata_foreach),
        (entry_parsed), (rb_podcast_parse_load_feed),
        (rb_podcast_parse_channel_free):
        * podcast/rb-podcast-parse.h: Use totem-pl-parser to parse Podcast
        files (including Atom files) (Closes: #355984), as well as OPML files

        * shell/rb-playlist-manager.c: (handle_playlist_entry_cb),
        (playlist_load_started_cb), (playlist_load_ended_cb),
        (rb_playlist_manager_parse_file), (_is_dirty_playlist),
        (rb_playlist_manager_save_playlists):
        * shell/rb-shell-player.c: (rb_shell_player_class_init),
        (rb_shell_player_handle_eos_unlocked), (rb_shell_player_init),
        (playlist_entry_cb), (open_location_thread),
        (rb_shell_player_open_location), (rb_shell_player_sync_play_order),
        (rb_shell_player_do_previous), (rb_shell_player_do_next_internal),
        (rb_shell_player_entry_activated_cb):
        * shell/rb-shell.c: (handle_playlist_entry_cb),
        (rb_shell_load_uri): Update API to totem-pl-parser 2.21.4, detect
        podcasts and OPML files (Closes: #489520) and add them to the
        podcast source

        * podcast/test-podcast-parse.c: (main): Call setlocale
        so we print UTF-8 characters

        (Closes: #484768)
Comment 12 Kern Handa 2008-01-04 14:13:47 UTC
Created attachment 102119 [details] [review]
Adds backwards compatibility for usage of totem-plparser.

This patch will add some backwards compatibility to rhythmbox when it comes to using totem-plparser. This version compiles with at least 2.20.0, but is quite likely that it will compile with even earlier version. I just wasn't able to test it out.
Comment 13 Jonathan Matthew 2008-01-04 21:39:35 UTC
That's the easy part.  The hard part is that totem-plparser < 2.21.0 did not do podcast parsing.
Comment 14 Bastien Nocera 2008-01-07 12:08:06 UTC
I removed backwards compatibility because it would require backporting a lot of code from totem-pl-parser 2.21.X to totem 2.20 (for the podcast support), as well as making the rhythmbox code unreadable.

Furthermore, the patch attached just won't work as signals within the library have changed.