Kodi Community Forum
[RELEASE] Canada On Demand (Successor to CTV Properties) - 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] Canada On Demand (Successor to CTV Properties) (/showthread.php?tid=97262)



- dwueppel - 2011-09-21

I just wanted to add my experience here as well. up until about a month ago things were working fine with CTV. Now I can't seem to get past viewing the listing of shows. When I click on a specific episode XBMC hangs. I checked the logs and there really wasn't anything of use in there. I'm running under Linux and I just updated rtmp to the 2.4 version but still no luck.

Good to hear about the CityTV stuff though, I'll give that a try tonight.


- richardgiroux - 2011-09-22

What is everybody running on?

I have a number of machines that I can use to test.

PVR is Windows XP - CityTV won't even load show menus.

Laptop is Windows 7 - CityTV won't even load show menus.

Work computer is OpenSuse 11 - CityTV works until I backup in the menu system.

For example, I can go into any show and play anything but if I press on the ".." on the menu system, I need to restart XBMC before I can play a video again.


- teefer22 - 2011-09-22

richardgiroux Wrote:What is everybody running on?

I have a number of machines that I can use to test.

PVR is Windows XP - CityTV won't even load show menus.

Laptop is Windows 7 - CityTV won't even load show menus.

Work computer is OpenSuse 11 - CityTV works until I backup in the menu system.

For example, I can go into any show and play anything but if I press on the ".." on the menu system, I need to restart XBMC before I can play a video again.

Hi,

I have:

XBMC Dharma 10.1 on Windows Vista - CityTV won't even load show menus.

ATV2 running 10.0-9 - CityTV..... is working. But I noticed that I do have to wait for all the thumbnails to load before I select a menu item or it won't load. Kinda strange. The difference must be that I'm using Dharma on my PC and a pre-eden on the atv2.


- Kaitlyn2004 - 2011-09-23

Does this plugin keep track of what you've watched by any chance?


- richardgiroux - 2011-09-24

Hello Everyone,

On my way home, I traced the loading menu issue to a file write issue in "default.py"

It seems there was a "stuck" file in the cache area of the plugin. I cleared the cache area for video on demand and voila, it works.

My path was:

C:\Users\Richard\AppData\Roaming\XBMC\userdata\addon_data\plugin.video.canada.on.demand\cache\video.citytv.com\...

I cleared all the directories below "video.citytv.com" and all is fine now.

I'll try the same thing on my home PVR later.


- jedix - 2011-09-30

So I came across a library that's used to access the brightcove stuff here:

http://github.com/studionow/pybrightcover

Think that would help with city, etc?


- jedix - 2011-09-30

dwueppel Wrote:I just wanted to add my experience here as well. up until about a month ago things were working fine with CTV. Now I can't seem to get past viewing the listing of shows. When I click on a specific episode XBMC hangs. I checked the logs and there really wasn't anything of use in there. I'm running under Linux and I just updated rtmp to the 2.4 version but still no luck.

Good to hear about the CityTV stuff though, I'll give that a try tonight.

Try disabling playing the series of clips, this was happening to me until I disabled that.


- pipman2006 - 2011-09-30

Just like to say upon testing out the hgtv and global channels you can follow the menus to the end but appear to be empty. This was on both windows 10.1 xbmc and apple tv 2


- jedix - 2011-09-30

pipman2006 Wrote:Just like to say upon testing out the hgtv and global channels you can follow the menus to the end but appear to be empty. This was on both windows 10.1 xbmc and apple tv 2

Yes, I found this with global in linux too..

I've been looking at the issue, and it appears that the encoding of the URL has changed. I added a fix, but it results in the librtmp handshake fail:

Code:
diff --git a/channels/theplatform.py b/channels/theplatform.py
index e830b66..43fa134 100644
--- a/channels/theplatform.py
+++ b/channels/theplatform.py
@@ -206,7 +206,15 @@ class ThePlatformBaseChannel(BaseChannel):
                 except ValueError:
                     base_url = decode_htmlentities(ref['src'])
                     playpath = None
-                logging.debug('all other channels type of SMIL  base_url=%s  playpath=%s'%(base_url, playpath))
+                    logging.debug('all other channels type of SMIL  base_url=%s  playpath=%s'%(base_url, playpath))
+            elif ref['src'].startswith('rtmpe://') :
+                try:
+                    base_url, playpath = decode_htmlentities(ref['src']).split('{break}', 1) #<break>
+                    logging.debug("RTMPE? ref= %s, base_url = %s, playpath = %s" %(ref['src'], base_url, playpath))
+                except ValueError:
+                    base_url = decode_htmlentities(ref['src'])
+                    playpath = None
+                    logging.debug("RTMPE? ref= %s, base_url = %s, playpath = %s" %(ref['src'], base_url, playpath))
             else:
                 if soup.meta['base'].startswith('rtmp://'): #CBC type of SMIL
                     base_url = decode_htmlentities(soup.meta['base'])

Please note that I'm not going to make a more complex RE until it's working..

I then pulled the new librtmp from git, built and installed..
Code:
git clone git://git.ffmpeg.org/rtmpdump;cd rtmpdump/;make;sudo make install

The handshake works again, but I receive an error:

(note this is ncis ep 1 on global..)
Code:
12:33:04 T:140283295561472    INFO: HandShake: Genuine Adobe Flash Media Server
12:33:04 T:140283295561472    INFO: HandShake: Handshaking finished....
12:33:04 T:140283295561472    INFO: RTMP_Connect1, handshaked
12:33:04 T:140283295561472    INFO: Invoking connect
12:33:04 T:140283295561472    INFO: RTMP_ClientPacket, received: invoke 134 bytes
12:33:04 T:140283295561472    INFO: (object begin)
12:33:04 T:140283295561472    INFO: Property: <Name:           no-name., STRING:        _error>
12:33:04 T:140283295561472    INFO: Property: <Name:           no-name., NUMBER:        1.00>
12:33:04 T:140283295561472    INFO: Property: NULL
12:33:04 T:140283295561472    INFO: Property: <Name:           no-name., OBJECT>
12:33:04 T:140283295561472    INFO: (object begin)
12:33:04 T:140283295561472    INFO: Property: <Name:              level, STRING:        error>
12:33:04 T:140283295561472    INFO: Property: <Name:               code, STRING:        NetConnection.Connect.Rejected>
12:33:04 T:140283295561472    INFO: Property: <Name:        description, STRING:        [ AccessManager.Reject ] : Access denied!>
12:33:04 T:140283295561472    INFO: (object end)
12:33:04 T:140283295561472    INFO: Previous line repeats 1 times.
12:33:04 T:140283295561472    INFO: HandleInvoke, server invoking <_error>
12:33:04 T:140283295561472   ERROR: rtmp server sent error
12:33:04 T:140283295561472    INFO: RTMP_ClientPacket, received: invoke 18 bytes
12:33:04 T:140283295561472    INFO: (object begin)
12:33:04 T:140283295561472    INFO: Property: <Name:           no-name., STRING:        close>
12:33:04 T:140283295561472    INFO: Property: <Name:           no-name., NUMBER:        0.00>
12:33:04 T:140283295561472    INFO: Property: NULL
12:33:04 T:140283295561472    INFO: (object end)
12:33:04 T:140283295561472    INFO: HandleInvoke, server invoking <close>
12:33:04 T:140283295561472   ERROR: rtmp server requested close
12:33:04 T:140283295561472   ERROR: CDVDPlayer::OpenInputStream - error opening [rtmpe://cp103996.edgefcs.net/ondemand?ovpfv=2.1.4&auth=dbEbic8adbnaRcVagdLbmc6avdWcDaUaBb2-boHCYv-bDW-iYG-9plDDo4qmHUwI0T2&aifp=v002&slist=videolink%2FNCIS901HD_lowest_16x9%3Bvideolink%2FNCIS901HD_low_16x9%3Bvideolink%2FNCIS901HD_medium_16x9%3Bvideolink%2FNCIS901HD_high_16x9%3Bvideolink%2FNCIS901HD_highest_16x9 playpath=mp4:videolink/NCIS901HD_highest_16x9.mp4]

This does seem to make SOME global and hgtv work again.. not sure if it's the lib or the code fix.. or both.

The error might be that it's trying to play the incorrect file.


- nick_wa - 2011-10-03

Anyone get Hockey Night in Canada stream up?


- jedix - 2011-10-03

I have a pull request into the maintainer for my fix above. I've slightly modified the logging.

If anyone has any ideas about the rtmp error of `access denied` I would very much appreciate any insight.

Thanks.


- jedix - 2011-10-03

nick_wa Wrote:Anyone get Hockey Night in Canada stream up?

I have not tried them, are there ones I could try at times when hockey is not on?


- jedix - 2011-10-04

I just tested my fix against NCIS, and it now works. I think this is good for all global and hgtv programs.

here's my git repo:
https://github.com/howlett/plugin.video.canada.on.demand

Please give it a try and see if it works for you.

Thanks.


- vijayk416 - 2011-10-04

Thank you for stepping up to help out!

I tried updating the plugin - it said it updated but I don't think anything took as the system still just times out HGtv. City also broken. Global plays but crashes 2-3 minutes in:

pastebin:
http://pastebin.com/BtdtcDbz


- jedix - 2011-10-04

vijayk416 Wrote:Thank you for stepping up to help out!

I tried updating the plugin - it said it updated but I don't think anything took as the system still just times out HGtv. City also broken. Global plays but crashes 2-3 minutes in:

pastebin:
http://pastebin.com/BtdtcDbz

How did you update the plugin? My repo hasn't been pulled into the main repo so if you just used to plugin update mechanism in xbmc, it won't work. You would have to do it by hand right now Sad That means either replacing or editing the file in addons/plugin.video.canada.on.demand/channels/theplatform.py and removing theplatform.pyo and theplatform.pyc so that the py file gets used.

My change wouldn't fix anything in regards to City, just global & hgtv. They both use the same "theplatform.py" file. City uses brightcover.py, it's another streaming framework. I have not played with the brightcover framework that much yet.

After looking into it, you need the new librtmp (or an older one) for sure. It seems that global needs the new handshake which doesn't work in 2.3 of librtmp.. some people report it working in 2.1, but it is for sure fixed in 2.4 which isn't in any linux distro at far as I'm aware (I have no idea about windows or osx). If librtmp is your issue, then you wouldn't get video at all.