Kodi Community Forum
[RELEASE] Hulu (Video) Plugin for XBMC - 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] Hulu (Video) Plugin for XBMC (/showthread.php?tid=42041)



Ok, I got further this time... - angrycamel - 2008-12-19

Well I got the networking issue worked out. Not sure what was going on, but I just retyped all of my static settings again and it worked.

Now I am still unable to play a 30 rock episode that RWParris2 said he could do.

Here is my debug log: (Looks like it can't see r.hulu.com) I get a 404 when I load r.hulu.com on my pc too. Does that help?

Code:
11:05:51 M: 17948672   DEBUG: CGUIMediaWindow::GetDirectory (plugin://video/Hulu/?mode=3&name=30+Rock%3A+A+Sound+Investment&url=http%3A%2F%2Fwww.hulu.com%2Fwatch%2F45647%2F30-rock-a-sound-investment&thumbnail=http%3A%2F%2Fthumbnails.hulu.com%2F12%2F684%2F53076_145x80_generated__f4pN3dCLpE652pwgCabkZA.jpg)
11:05:51 M: 17948672   DEBUG:   ParentPath = [plugin://video/Hulu/?mode=2&name=30+Rock]
11:05:51 M: 17948672   DEBUG: DIRECTORY::CPluginDirectory::GetDirectory - URL for plugin settings: Hulu/
11:05:51 M: 17948672   ERROR: Unable to load: Q:\plugins\video\Hulu\resources\settings.xml, Line 0
                             Failed to open file
11:05:51 M: 17948672   DEBUG: unable to load Q:\plugins\video\Hulu\resources\language\english\strings.xml: Failed to open file at line 0
11:05:51 M: 17948672   DEBUG: DIRECTORY::CPluginDirectory::GetDirectory - calling plugin Q:\plugins\video\Hulu\default.py('plugin://video/Hulu/','1','?mode=3&name=30+Rock%3A+A+Sound+Investment&url=http%3A%2F%2Fwww.hulu.com%2Fwatch%2F45647%2F30-rock-a-sound-investment&thumbnail=http%3A%2F%2Fthumbnails.hulu.com%2F12%2F684%2F53076_145x80_generated__f4pN3dCLpE652pwgCabkZA.jpg')
11:05:51 M: 17948672   DEBUG: LoadLibraryA('python24.dll')
11:05:51 M: 16826368   DEBUG: LoadLibrary('python24.dll') returning: 01767120
11:05:51 M: 16826368   DEBUG: dllGetProcAddress(007921A0(kernel32.dll), 'InterlockedCompareExchange') => 00260F34
11:05:51 M: 16560128   DEBUG: GetModuleFileNameA(00000000, 1E102490, 256) => 'xbmc.xbe'
11:05:51 M: 16560128   DEBUG: advapi32.dll fake function RegQueryInfoKeyA called
11:05:51 M: 16560128   DEBUG: advapi32.dll fake function RegQueryInfoKeyA called
11:05:51 M: 16502784   DEBUG: LoadLibraryExA called with flags:
                              - LOAD_WITH_ALTERED_SEARCH_PATH
11:05:51 M: 16506880   DEBUG: LoadLibraryA('zlib.pyd')
11:05:51 M: 16437248   DEBUG: kernel32.dll fake function DisableThreadLibraryCalls called
11:05:51 M: 16437248   DEBUG: LoadLibrary('zlib.pyd') returning: 01070AA0
11:05:51 M: 16437248   DEBUG: dllGetProcAddress(1E1B0000(zlib.pyd), 'initzlib') => 1E1B2150
11:05:51 M: 15548416  NOTICE: -->Python Initialized<--
11:05:51 M: 15548416  NOTICE:
11:05:51 M: 15024128   DEBUG: DIRECTORY::CPluginDirectory::WaitOnScriptResult - waiting on the Hulu plugin...
11:05:52 M: 14245888   DEBUG: LoadLibraryExA called with flags:
                              - LOAD_WITH_ALTERED_SEARCH_PATH
11:05:52 M: 14245888   DEBUG: LoadLibraryA('_socket.pyd')
11:05:52 M: 14196736   DEBUG: kernel32.dll fake function DisableThreadLibraryCalls called
11:05:52 M: 14196736   DEBUG: LoadLibrary('_socket.pyd') returning: 01546CA0
11:05:52 M: 14196736   DEBUG: dllGetProcAddress(1E1D0000(_socket.pyd), 'init_socket') => 1E1D4BF0
11:05:52 M: 14196736   DEBUG: LoadLibraryExA called with flags:
                              - LOAD_WITH_ALTERED_SEARCH_PATH
11:05:52 M: 14196736   DEBUG: LoadLibraryA('_ssl.pyd')
11:05:52 M: 13701120   DEBUG: Unable to resolve msvcr71.dll _getch
11:05:52 M: 13701120   DEBUG: Unable to resolve kernel32.dll FlushConsoleInputBuffer
11:05:52 M: 13701120   DEBUG: kernel32.dll fake function DisableThreadLibraryCalls called
11:05:52 M: 13701120   DEBUG: LoadLibrary('_ssl.pyd') returning: 0161F6F0
11:05:52 M: 13701120   DEBUG: dllGetProcAddress(02B10000(_ssl.pyd), 'init_ssl') => 02B11820
11:05:52 M: 13701120   DEBUG: kernel32.dll fake function SetConsoleCtrlHandler called
11:05:52 M: 13688832   DEBUG: dllGetProcAddress(00792A28(advapi32.dll), 'CryptAcquireContextA') => 0023713E
11:05:52 M: 13688832   DEBUG: dllGetProcAddress(00792A28(advapi32.dll), 'CryptGenRandom') => 0023714F
11:05:52 M: 13688832   DEBUG: advapi32.dll fake function dllCryptAcquireContext() called
11:05:52 M: 10178560    INFO: Loading skin file: DialogBusy.xml
11:05:52 M: 10145792   DEBUG: Load DialogBusy.xml: 70.30ms
11:05:52 M: 10129408   DEBUG: Alloc resources: 75.67ms (75.66 ms skin load, 0.01 ms preload)
11:05:53 M:  9437184    INFO: Loading skin file: DialogProgress.xml
11:05:53 M:  9572352   DEBUG: Load DialogProgress.xml: 32.54ms
11:05:53 M:  9531392   DEBUG: Alloc resources: 15.85ms (0.00 ms skin load, 0.34 ms preload)
11:05:54 M: 11952128  NOTICE: HULU -> Start
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: Mode: 3
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: URL: http://www.hulu.com/watch/45647/30-rock-a-sound-investment
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: Name: 30 Rock: A Sound Investment
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: Thumbnail: http://thumbnails.hulu.com/12/684/53076_145x80_generated__f4pN3dCLpE652pwgCabkZA.jpg
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: Handle : 1
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128  NOTICE: Episode
11:05:54 M: 11952128  NOTICE:
11:05:54 M: 11952128   DEBUG: LoadLibraryA('ws2_32')
11:05:54 M: 11952128   DEBUG: LoadLibrary('ws2_32.dll') returning: 00792178
11:05:54 M: 11952128   DEBUG: dllGetProcAddress(00792138(ws2_32.dll), 'getaddrinfo') => 0023A650
11:05:54 M: 11952128   DEBUG: dllGetProcAddress(00792138(ws2_32.dll), 'getaddrinfo') => 0023A650
11:05:54 M: 11952128   DEBUG: dllGetProcAddress(00792138(ws2_32.dll), 'getnameinfo') => 0023A66B
11:05:54 M: 11952128   DEBUG: dllGetProcAddress(00792138(ws2_32.dll), 'freeaddrinfo') => 0023A68F
11:05:55 M: 11837440  NOTICE: Found 12234646
11:05:55 M: 11837440  NOTICE:
11:05:55 M: 11952128  NOTICE: HULU -> Content ID : 12234646
11:05:55 M: 11952128  NOTICE:
11:06:02 M: 11952128   ERROR: DNS lookup for r.hulu.com failed: 10060
11:06:02 M: 11952128  NOTICE: Traceback (most recent call last):
11:06:02 M: 11952128  NOTICE:   File "Q:\plugins\video\Hulu\default.py", line 372, in ?
11:06:02 M: 11952128  NOTICE:
11:06:02 M: 11960320  NOTICE: getEpisode(name, url)
11:06:02 M: 11952128  NOTICE:   File "Q:\plugins\video\Hulu\default.py", line 93, in getEpisode
11:06:02 M: 11952128  NOTICE:
11:06:02 M: 11952128  NOTICE: response = urllib2.urlopen(req)
11:06:02 M: 11952128  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 130, in urlopen
11:06:02 M: 11952128  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 358, in open
11:06:02 M: 11952128  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 376, in _open
11:06:02 M: 11874304  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 337, in _call_chain
11:06:02 M: 11960320  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 1021, in http_open
11:06:02 M: 11952128  NOTICE:   File "Q:\system\python\python24.zlib\urllib2.py", line 996, in do_open
11:06:02 M: 11952128  NOTICE: urllib2
11:06:02 M: 11952128  NOTICE: .
11:06:02 M: 11952128  NOTICE: URLError
11:06:02 M: 11952128  NOTICE: :
11:06:02 M: 11952128  NOTICE: <urlopen error (4, 'getaddrinfo failed')>
11:06:02 M: 11952128  NOTICE:
11:06:02 M: 11952128   ERROR: Scriptresult: Error
11:06:02 M: 11952128    INFO: Python script stopped
11:06:02 M: 12476416    INFO: Python, unloading python24.dll because no scripts are running anymore
11:06:02 M: 12476416  NOTICE:
11:06:02 M: 12476416  NOTICE:
11:06:03 M: 12578816   DEBUG: Q:\system\python\DLLs\_socket.pyd: Detected 1 unloaded dll's
11:06:03 M: 12627968   DEBUG: Q:\system\python\DLLs\_ssl.pyd (base 02B10000): Detected memory leaks: 1647 leaks
11:06:03 M: 12627968   DEBUG: leak caller address  2b1489b, size    20064, counter 1645
11:06:03 M: 12627968   DEBUG: leak caller address  2b148b0, size     4224, counter    2
11:06:03 M: 12627968   DEBUG: _ssl.pyd: Total bytes leaked: 24288
11:06:03 M: 13127680   DEBUG: Q:\system\python\python24.dll (base 1E000000): Detected memory leaks: 583 leaks
11:06:03 M: 16711680   DEBUG: leak caller address 1e0211cb, size       24, counter    1
11:06:03 M: 16711680   DEBUG: leak caller address 1e046f57, size   500160, counter  102
11:06:03 M: 16711680   DEBUG: leak caller address 1e04ff6b, size     1000, counter    1
11:06:03 M: 16711680   DEBUG: leak caller address 1e058c2c, size      233, counter    1
11:06:03 M: 16711680   DEBUG: leak caller address 1e05cddb, size    34580, counter   35
11:06:03 M: 16711680   DEBUG: leak caller address 1e05e5ef, size     1976, counter    2
11:06:03 M: 16711680   DEBUG: leak caller address 1e060ea5, size      912, counter   33
11:06:03 M: 16711680   DEBUG: leak caller address 1e060f81, size       84, counter    5
11:06:03 M: 16711680   DEBUG: leak caller address 1e072c5f, size  3145728, counter   12
11:06:03 M: 16711680   DEBUG: leak caller address 1e072cac, size       64, counter    1
11:06:03 M: 16711680   DEBUG: leak caller address 1e072e88, size    61548, counter  115
11:06:03 M: 16711680   DEBUG: leak caller address 1e072fc9, size     9743, counter  266
11:06:03 M: 16711680   DEBUG: leak caller address 1e091e3f, size      640, counter    3
11:06:03 M: 16711680   DEBUG: leak caller address 1e093bec, size       72, counter    6
11:06:03 M: 16711680   DEBUG: python24.dll: Total bytes leaked: 3756764
11:06:03 M: 17838080   DEBUG:  DIRECTORY::CPluginDirectory::WaitOnScriptResult - plugin exited prematurely - terminating



- tslayer - 2008-12-19

Still DNS issues: ERROR: DNS lookup for r.hulu.com failed: 10060

You still have network issues. Gotta fix those first.


- angrycamel - 2008-12-19

tslayer Wrote:Still DNS issues: ERROR: DNS lookup for r.hulu.com failed: 10060

You still have network issues. Gotta fix those first.

angrycamel Wrote:(Looks like it can't see r.hulu.com) I get a 404 when I load r.hulu.com on my pc too.


I can ping it from my pc to 209.170.118.16. I am not sure why it wont work from the xbox when everything else works.

Code:
Microsoft Windows XP [Version 5.1.2600]
(C) Copyright 1985-2001 Microsoft Corp.

C:>ping r.hulu.com

Pinging a1826.g.akamai.net [209.170.118.16] with 32 bytes of data:

Reply from 209.170.118.16: bytes=32 time=11ms TTL=253
Reply from 209.170.118.16: bytes=32 time=13ms TTL=253
Reply from 209.170.118.16: bytes=32 time=12ms TTL=253
Reply from 209.170.118.16: bytes=32 time=16ms TTL=253

Ping statistics for 209.170.118.16:
    Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
    Minimum = 11ms, Maximum = 16ms, Average = 13ms

C:>

Does anyone have any ideas?


- tslayer - 2008-12-19

It throws a 404 if accessed directly, but it dns lookup on it works fine.

Ignore trying to goto it directly. You are still having DNS issues. Try some other DNS IPs such as 4.2.2.2 or 4.2.2.1.


- mique - 2008-12-19

@ reparris2

I am in USA
All the menu tv programs that I can see all navigate to the episode to play but when requested to play, nothing happens.
If I can give you more information please let me know.


I got 30 Rock playing - angrycamel - 2008-12-19

tslayer Wrote:It throws a 404 if accessed directly, but it dns lookup on it works fine.

Ya, I noticed that when I pinged it.

tslayer Wrote:Try some other DNS IPs such as 4.2.2.2 or 4.2.2.1.
Thanks for the tip. I had the DNS address set to my router's address which is a Verizon Fios supplied router, so maybe that thing has some issues.

After trying with the DSN IP you gave (4.2.2.2), it worked perfectly.

Thanks for the tip!


Whoa - philipacentaur - 2008-12-19

Thanks for posting that RTMP build, man.

This plugin is working great! I'm using the modified script with all the movies and shows, and I really haven't found anything that hasn't worked yet. Is someone working on a scraper for this? It would be awesome to integrate library support.

Anyway, nice job!


- rwparris2 - 2008-12-19

philipacentaur Wrote:Thanks for posting that RTMP build, man.

This plugin is working great! I'm using the modified script with all the movies and shows, and I really haven't found anything that hasn't worked yet. Is someone working on a scraper for this? It would be awesome to integrate library support.

Anyway, nice job!

Building isn't so hard, you just download some stuff, click a bat file, and poof you've got a nice xbmc.rar
zoltar12 should get all the credit here as he's the one who made the patch.

I'm working on a scraper for the plugin itself when I have time (actually I've got all the code I just have to port it to something xbmc likes) but it won't be added to the library until someone makes the library compatible with launching python.

Here is my idea of how to handle it:
http://forum.xbmc.org/showthread.php?tid=34443 + http://trac.xbmc.org/ticket/5442

Glad it is working for someone.

@mique will Family Guy play? Family Guy should play no matter what, if it doesn't you've problems beyond what the patch fixes.

@zoltar12:
would you mind explaining how that patch works? I swear it looks like all it does is cut the string off at the ';' but obviously there is something more to it...


- mique - 2008-12-20

@ rwparris2

No, Family Guy will not Play.

Let's make sure my set up is correct, I loaded your patched xbmc to my Xbox. I have installed the Hulu Plugin which I activate to get to all the menu's. I see all the choices but for some reason nothing plays. I get nothing, so I press select again and get the following error box "Playlist Playback Aborted, To Many Consecutive Fake Items"
Does this shed some light?
Cheers


- angrycamel - 2008-12-20

mique Wrote:No, Family Guy will not Play.

Let's make sure my set up is correct, I loaded your patched xbmc to my Xbox. I have installed the Hulu Plugin which I activate to get to all the menu's. I see all the choices but for some reason nothing plays. I get nothing, so I press select again and get the following error box "Playlist Playback Aborted, To Many Consecutive Fake Items"
Does this shed some light?
Cheers

Can you turn on debug logging in the control panel and try again? Once you do, grab the xbmc.log that gets created by FTP'ing to your xbox. Its in the root of your XBMC folder.

You must turn on debug logging then try the hulu scriupt again so that it will write the errors into the log. Then just paste the pertinent log contents here in a code block for us to check out.


- mique - 2008-12-20

OK - Debug Log is activated.

How do I paste in a 'code Block'

Thanks


- rwparris2 - 2008-12-20

mique Wrote:How do I paste in a 'code Block'

You can either use a paste site like http://pastebin.ca/ or http://nopaste.com
Or you can paste the contents into the reply box, highlight it, and click the hash symbol in the forum's toolbar. It looks like a #.
It will insert [ CODE ] [ / CODE] around whatever you've highlighted.

You can use the preview button to make sure it looks right. If it complains about it being too long, just use one of the paste sites.


- mique - 2008-12-20

rwparris2 Wrote:You can either use a paste site like http://pastebin.ca/ or http://nopaste.com
Or you can paste the contents into the reply box, highlight it, and click the hash symbol in the forum's toolbar. It looks like a #.
It will insert [ CODE ] [ / CODE] around whatever you've highlighted.

You can use the preview button to make sure it looks right. If it complains about it being too long, just use one of the paste sites.

OK Here it is http://pastebin.ca/1289875


- JeffElkins - 2008-12-20

In all honesty I have to ask about Boxee. How come XBMC can't use Boxee's Hulu code? Are they taking from XBMC and not giving back?


- jmarshall - 2008-12-20

The code is available for most of what is required (and the rest of it is just 2 executables which may or may not become available separately). I'm not sure what it offers above what this plugin offers though.

In any case, it's US only pretty much, and as most of our developers are outside of the US, we're not all that interested in it!

Cheers,
Jonathan