Kodi Community Forum
[RELEASE] Free Cable - US station aggregator - Printable Version

+- Kodi Community Forum (https://forum.kodi.tv)
+-- Forum: Support (https://forum.kodi.tv/forumdisplay.php?fid=33)
+--- Forum: Add-on Support (https://forum.kodi.tv/forumdisplay.php?fid=27)
+---- Forum: Video Add-ons (https://forum.kodi.tv/forumdisplay.php?fid=154)
+---- Thread: [RELEASE] Free Cable - US station aggregator (/showthread.php?tid=101938)



RE: [RELEASE] Free Cable - US station aggregator - lilsprout00 - 2013-04-02

Having the same problem here as well. We watched Amazing race late last night. This afternoon, the listing refreshed and now the only option under any CBS show is parent directory return '..'

No errors reported. Free Cable lists all CBS shows, but no choices after the show level.


RE: [RELEASE] Free Cable - US station aggregator - someoneelse2 - 2013-04-02

I noted the same problem with CBS not returning any episodes. After some brief inspection of the debug/code it looks like the CBS.com site changed the carousel so it no longer finds the episodes.


RE: [RELEASE] Free Cable - US station aggregator - hexe - 2013-04-02

Having the same issue myself with CBS. :/ Also ABC Family no longer works as of this year. Anybody got a fix?


RE: [RELEASE] Free Cable - US station aggregator - Eye in the sky - 2013-04-02

ABC Family stopped working months ago.


RE: [RELEASE] Free Cable - US station aggregator - jjslegacy - 2013-04-03

Yep having bad luck lately with website changes, abc rss not completely being updated with latest episodes and cbs showing nothing.


RE: [RELEASE] Free Cable - US station aggregator - billolzak - 2013-04-03

Anyone have any ideas or know if this is being addressed?


RE: [RELEASE] Free Cable - US station aggregator - mmatforum - 2013-04-05

I'm having the same issue with CBS shows. Any news?


RE: [RELEASE] Free Cable - US station aggregator - locoguano - 2013-04-05

This is one of those addons that takes A LOT of work to maintain. I know nothing about coding, but maybe those of you that do can look at the code and create some individual addons for the major networks that you can maintain... This way all of the work isn't dumped on BlueCop.


RE: [RELEASE] Free Cable - US station aggregator - jjslegacy - 2013-04-05

well said - this is a huge addon that is a complete moving target. we definitely need a way to support BlueCop more and get some more smart developer folks to keep it current.

I haven't coded in years but will certainly be taking a look and trying where I can.


RE: [RELEASE] Free Cable - US station aggregator - andyman - 2013-04-06

I am a complete noob to plugins, so there is a lot of room for optimization, but I was able to have some success with these updates. At least I can watch some shows again, but some of the meta data is missing because it's not in the JSON file. Maybe somebody else can have a look... Everything is in the cbs.py file.

First, re-wrote the showcats routine, so comment out the old one and add this code:
Code:
def showcats(url = common.args.url):
    data = common.getURL(url)
    try:
        print 'CBS: Trying April 2013 Carousel'
        tree=BeautifulSoup(data, convertEntities=BeautifulSoup.HTML_ENTITIES)
        categories = re.compile("id-carousel-(\d+)").findall(str(tree))
        for catId in categories:
            thisUrl = 'http://www.cbs.com/carousels/videosBySection/'+catId+'/0/40/'
            data = common.getURL(thisUrl)
            name = demjson.decode(data)['result']['title']
            common.addDirectory(name, 'cbs', 'newvideos2', thisUrl)
    except:
        print 'CBS: April 2013 Carousel failed'
    common.setView('seasons')

Next, a new video parsing routine (lots of the elements are missing now), so just add this after the "newvideos":
Code:
def newvideos2(url = common.args.url):
    data = common.getURL(url)
    itemList = demjson.decode(data)['result']['videos']
    for video in itemList:
        url = 'http://www.cbs.com' + video['url']
        description = 'description'
        thumb = video['thumb']['small']
        seriesTitle = video['series_title']
        title = video['label']
        try:episodeNum = int(video['episodeNum'])
        except:episodeNum = 0
        try:seasonNum = int(video['seasonNum'])
        except:seasonNum = 0
        duration = 0
        airDate = 0
        rating = 0
        u = sys.argv[0]
        u += '?url="'+urllib.quote_plus(url)+'"'
        u += '&mode="cbs"'
        u += '&sitemode="play"'
        displayname = '%sx%s - %s' % (seasonNum,episodeNum,title)
        infoLabels={ "Title":title,
                     "Plot":description,
                     "Season":seasonNum,
                     "Episode":episodeNum,
                     "premiered":airDate,
                     "Duration":str(duration),
                     "mpaa":rating,
                     "TVShowTitle":seriesTitle
                     }
        common.addVideo(u,displayname,thumb,infoLabels=infoLabels)
    common.setView('episodes')

Last step, modify the beginning of the "play" routine with this partial snippet (the javascript variable definition changed):
Code:
def play(url = common.args.url):
    print "DEBUG Entering play function"
    swfUrl = 'http://can.cbs.com/thunder/player/chrome/canplayer.swf'
    if 'http://' in url:
        data=common.getURL(url)
        try:
            pid = re.compile('video.settings.pid = "(.*?)";').findall(data)[0]
        except:
            pid = re.compile("video.settings.pid = '(.*?)';").findall(data)[0]
    else:
        pid = url



RE: [RELEASE] Free Cable - US station aggregator - jasongorham - 2013-04-06

I just spent 30 minutes working out how to edit that file and uploading it etc.. (I really have no idea what I am doing).. For me, it worked, so thank you very much for that :-) I can now watch CBS shows again. I joined just to say thank you!


RE: [RELEASE] Free Cable - US station aggregator - sldt - 2013-04-06

Thank you so much andyman! Your fixes worked for me! I hope to someday contribute here - just learning python.


RE: [RELEASE] Free Cable - US station aggregator - Eye in the sky - 2013-04-06

Please upload the working cbs.py file.


RE: [RELEASE] Free Cable - US station aggregator - slices - 2013-04-06

My daughter wanted to watch word girl on PBS Kids. However it wasn't showing up. Looking at the log I noticed the URL had &query=CustomBoolean|isPreschool|true in it.

Editing pbskids.py and removing that bit of the url both places it appears has solved the issue and all PBS Kids episodes appear not just those classed as preschool.

Alex


RE: [RELEASE] Free Cable - US station aggregator - gate1975mlm - 2013-04-06

(2013-04-06, 04:20)jasongorham Wrote: I just spent 30 minutes working out how to edit that file and uploading it etc.. (I really have no idea what I am doing).. For me, it worked, so thank you very much for that :-) I can now watch CBS shows again. I joined just to say thank you!


Could you share the file with us please Smile

Thanks