RSS Problem in Plex/9

Hey guys, I hope this is the right forum for this, rather than the bugs forum.



Anyway, I have a plugin, the CBC plugin, and for certain sections it uses the Plex Media Server’s RSS functionality to get videos. In plex 8, this continues to work just fine, but in Plex 9, choosing the menu options that rely on RSS feeds just result in an empty menu. Does that make sense? Basically I have, for example, a section called “The National On Demand”. Choosing that should cause plex to grab the list of the most recent episodes of The National On Demand from the RSS feed for its video podcast. In plex 8 this still works fine, but in Plex 9, I just get an empty list rather than a list of episodes. FWIW, the console log just spits out a bunch of nonsense:



2010-09-13 10:58:07,447 - com.plexapp.plugins.cbcnewsnetwork (-4faed000) :  DEBUG (runtime) - Calling function 'GetRSS'2010-09-13 10:58:56,318 - com.plexapp.plugins.cbcnewsnetwork (-4faed000) :  DEBUG (runtime) - Handling request /video/cbc/:/function/GetRSS?function_args=Y2VyZWFsMQozCmRpY3QKZGljdApGcmFtZXdvcmsub2JqZWN0cy5JdGVtSW5mb1JlY29yZAozCnMxNApBdCBJc3N1ZSBQYW5lbHM2CnRpdGxlMnIyCnM2CnNlbmRlcnM3CkF0SXNzdWVzNApzaG93NApzMTQKQXQgSXNzdWUgUGFuZWxzOQppdGVtVGl0bGVzMwpDQkNzNgp0aXRsZTFzNApOZXdzczYKdGl0bGUyczM4Ci92aWRlby9jYmMvOi9yZXNvdXJjZXMvYXJ0LWRlZmF1bHQucG5nczMKYXJ0cjEKcjAK<br />
<br />
<br />
2010-09-13 10:58:56,325 - com.plexapp.plugins.cbcnewsnetwork (-4faed000) :  DEBUG (runtime) - Calling function 'GetRSS'




Where the function GetRSS is:

def GetRSS(sender, title2, show=""):<br />
	if show == "NoD":<br />
		dataURL = "http://www.cbc.ca/podcasting/includes/thenational-video-podcast.xml"<br />
		thumb = R('bg-yourNational.jpg')<br />
	elif show == "AtIssue":<br />
		dataURL = "http://www.cbc.ca/mediafeeds/rss/cbc/atissue-video-podcast.xml"<br />
		thumb = R('atissue.png')<br />
	elif show == "RexMurphy":<br />
		dataURL = "http://www.cbc.ca/mediafeeds/rss/cbc/rexmurphy-video-podcast.xml"<br />
		thumb = R('rexmurphy.jpg')<br />
	cbcRSS = RSS.FeedFromURL(dataURL, cacheTime=600)['entries']<br />
	dir = MediaContainer(viewGroup="InfoList", title2=title2)<br />
	for clip in cbcRSS:<br />
		title = clip['title']<br />
		summary = clip['summary']<br />
		url = clip['link']<br />
		length = int(clip['itunes_duration']) * 1000<br />
		dir.Append(VideoItem(url, title, thumb=thumb, summary=summary, duration=length))<br />
	return dir




Any thoughts on where I should start looking for the problem, or if this is some kind of bug in plex 9?

Thanks for the help.

There are still some bugs in the v2 of the plugin framework that are being ironed out. I too had an issue with RSS feeds in one of mine last week, and this sounds very similar. The developers are aware of it.



Jonny

This could be your (temporary) solution. It’s less clean than with the RSS.FeedFromURL functions, but in the end the result is the same.



<br />
def GetRSS(sender, title2, show=""):<br />
        if show == "NoD":<br />
                dataURL = "http://www.cbc.ca/podcasting/includes/thenational-video-podcast.xml"<br />
                thumb = R('bg-yourNational.jpg')<br />
        elif show == "AtIssue":<br />
                dataURL = "http://www.cbc.ca/mediafeeds/rss/cbc/atissue-video-podcast.xml"<br />
                thumb = R('atissue.png')<br />
        elif show == "RexMurphy":<br />
                dataURL = "http://www.cbc.ca/mediafeeds/rss/cbc/rexmurphy-video-podcast.xml"<br />
                thumb = R('rexmurphy.jpg')<br />
        cbcRSS = XML.ElementFromURL(dataURL, cacheTime=600).xpath('/rss/channel/item')<br />
        dir = MediaContainer(viewGroup="InfoList", title2=title2)<br />
        for clip in cbcRSS:<br />
                title = clip.xpath('./title')[0].text<br />
                summary = clip.xpath('./itunes:summary', namespaces={'itunes':'http://www.itunes.com/dtds/podcast-1.0.dtd'})[0].text<br />
                url = clip.xpath('./link')[0].text<br />
                length = clip.xpath('./itunes:duration', namespaces={'itunes':'http://www.itunes.com/dtds/podcast-1.0.dtd'})[0].text<br />
                length = int(length) * 1000<br />
                dir.Append(VideoItem(url, title, thumb=thumb, summary=summary, duration=length))<br />
        return dir<br />




Awesome, thanks!

This topic was automatically closed 90 days after the last reply. New replies are no longer allowed.