Page 4 of 15 FirstFirst ... 2345614 ... LastLast
Results 31 to 40 of 142

Thread: NBC's Olympic Videos Won't Play on Linux

  1. #31
    Join Date
    Sep 2007
    Location
    Cergy, France
    Beans
    6
    Distro
    Ubuntu 10.10 Maverick Meerkat

    Re: NBC's Olympic Videos *Will* Play on Linux

    Hi K_I_K,

    Thanks for the script !

    Just a quick question - I'm getting an import error below when I run your script on Ubuntu Hardy i386 on Python 2.5.2 (preinstalled on the OS). I'm a bit new here, can you tell me what I'm doing wrong, please? Is there some dependency that needs to be fulfilled here? Thank you once again in advance. Please find the CLI below -

    me@lenovo:~/Desktop$ python --version
    Python 2.5.2

    me@lenovo:~/Desktop$ python nbcsched.py
    Traceback (most recent call last):
    File "nbcsched.py", line 6, in <module>
    from xml.dom.ext.reader import PyExpat
    ImportError: No module named ext.reader
    me@lenovo:~/Desktop$

  2. #32
    Join Date
    Aug 2008
    Beans
    15

    Re: NBC's Olympic Videos Won't Play on Linux

    Here are the python packages with 'xml' in them that I have installed. It's got to be in one of them:
    Code:
    python-libxml2
    python-lxml
    python-xml

  3. #33
    Join Date
    Sep 2007
    Beans
    69

    Re: NBC's Olympic Videos Won't Play on Linux

    k_i_k
    That works great. I used your script and opened up the stream in vlc... I have to say it's better than viewing it from within the browser.
    Thank you.

  4. #34
    Join Date
    Dec 2006
    Beans
    17

    Re: NBC's Olympic Videos Won't Play on Linux

    This seems like a really promising solution, but I'm getting the same errors even after installing the dependencies (ImportError: No module named ext.reader). I did a lot of google searches, but I can't find a good fix. It seems like it is relying on an older pyxml rather than python-xml. Does anyone know how to fix this? I'm using Hardy on a 64-bit.

    I found this website that gives a fix, but I don't know how to use it: http://debianclub.org/aggregator/sources/2?page=33

    Fix/workaround:
    + sys.path.append('/usr/lib/python%s/site-packages/oldxml' % sys.version[:3])
    from xml.dom.ext.reader import HtmlLib

    Where would I type this?
    Last edited by globose; August 11th, 2008 at 05:51 PM.

  5. #35
    Join Date
    Sep 2006
    Beans
    70

    Re: NBC's Olympic Videos Won't Play on Linux

    Hey thank you k_i_k for that script... looks like it works, unfortunately there's nothing on right now

  6. #36
    Join Date
    Aug 2008
    Beans
    15

    Re: NBC's Olympic Videos *Will* Play on Linux

    An update. NBC also has lots of stuff recored, so you can watch something you missed when it was live. The new version scans these links too. Here's how to use it:

    Code:
    ./nbcsched.py <sport> <live | rewind> <pattern>
    <sport> is the sport you are interested (badminton, tennis, volleyball, etc)

    The second argument is either "live" or "rewind" for live streams or prerecorded ones.

    The third argument is matched against the description for each stream, and only the matching streams are looked up. This is useful when there are many "Rewind" links, as processing them all would take several minutes.

    Spread the joy! :-)
    Attached Files Attached Files
    Last edited by k_i_k; August 11th, 2008 at 08:22 PM.

  7. #37
    Join Date
    Nov 2007
    Location
    Chicago
    Beans
    226
    Distro
    Ubuntu 9.04 Jaunty Jackalope

    Re: NBC's Olympic Videos Won't Play on Linux

    And Microsoft drives more customers to piracy...

    EDIT: not referring to the script above, just in general

    Could someone make a tutorial for how to use this script and open the stream in VLC?
    Last edited by ace007; August 11th, 2008 at 10:36 PM.

  8. #38
    Join Date
    Aug 2008
    Beans
    15

    Re: NBC's Olympic Videos Won't Play on Linux

    Quote Originally Posted by ace007 View Post
    Could someone make a tutorial for how to use this script and open the stream in VLC?
    Umm, ace007, run the script and feed the stream URLs to VLC or another video player. No output means no streams were found or if any were they couldn't be parsed. Some/many "Rewind" streams may not work (no idea why). Read the code for details.

  9. #39
    Join Date
    Jul 2008
    Beans
    13

    Re: NBC's Olympic Videos Won't Play on Linux

    Quote Originally Posted by globose View Post
    This seems like a really promising solution, but I'm getting the same errors even after installing the dependencies (ImportError: No module named ext.reader). I did a lot of google searches, but I can't find a good fix. It seems like it is relying on an older pyxml rather than python-xml. Does anyone know how to fix this? I'm using Hardy on a 64-bit.

    I found this website that gives a fix, but I don't know how to use it: http://debianclub.org/aggregator/sources/2?page=33

    Fix/workaround:
    + sys.path.append('/usr/lib/python%s/site-packages/oldxml' % sys.version[:3])
    from xml.dom.ext.reader import HtmlLib

    Where would I type this?


    Yo, I figured out how to get this to work:
    Change the beginning of the script to look like this:

    Code:
    import re
    import sys
    
    from sys import argv
    from urllib import urlopen
    sys.path.append('/usr/lib/python2.5/site-packages/oldxml')
    from xml.dom import Node
    from xml.dom.ext.reader import PyExpat
    reader = PyExpat.Reader()
    Basically, you have to add an import sys and then use that to append to the path. Replace the 2.5 with whatever version you have, or use that general one in the one you found.

    Nice work KiK. This is excellent.

  10. #40
    Join Date
    Jun 2008
    Beans
    1

    Re: NBC's Olympic Videos Won't Play on Linux

    Great script! However, I seem to not get any audio on these streams. VLC works fine on files, etc. but nothing here? Is this the same for all?

Page 4 of 15 FirstFirst ... 2345614 ... LastLast

Tags for this Thread

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •