pyTivo - Transcoding server

Discussion in 'TiVo Home Media Features & TiVoToGo' started by armooo, Nov 25, 2006.

  1. innocentfreak

    innocentfreak Well-Known Member

    Aug 25, 2001


    That's what it is. I need to just dump this POS actiontec router. I had an older FiOS router which blocks it by default and the page is hidden so I have to dig up the link to stop it from filtering multicast. When I got the new FiOS router I had to reset up the Actiontec, and forgot about the setting.
  2. mlippert

    mlippert Active Member

    Apr 2, 2010
    I just wanted to let users of pytivo know that I've made changes for myself that others might find useful.

    Upfront disclaimer: I've been the only one using the version w/ my changes so only my use cases have seen any testing.
    In particular this means:
    • it's never been tried on the Mac
    • I have no idea if running as a service on MS Windows still works
    • I've mostly been downloading TS files and not decoding them (I do that later w/ VRD)

    My major personal impetus for making the changes was to get better information about the sync errors when downloading using transport stream (TS) from my tivos and to do that I used @Dan203's changes from his fork. I was also hoping to make finding TiVos on my LAN more reliable (I'm not sure if I succeeded in that or not).

    To that end my fork at GitHub - mlippert/pytivo: pyTivo is both an HMO and GoBack server. Similar to TiVo Desktop pyTivo loads many standard video compression codecs and outputs mpeg2 video to the TiVo. However, pyTivo is able to load MANY more file types than TiVo Desktop.:
    • Converts the existing @wmcbrine codebase from Python 2 to Python 3
    • removes copied python packages and uses the latest version from the environment (pip)
    • moves some settings in the pytivo.conf file into a new [togo] section
    • TS downloads always create a *.syncerr.yaml file detailing the results of the download attempts
    • I've added an option 'all' to the 'ignore', 'reject', 'best' options created by @Dan203
    • You can customize the name of downloaded files w/ 2 new conf settings episode_fn & movie_fn
    • I've tweaked the logging a fair bit in order to get more debug information, but have regular logging be more discerning.

    Here's the changelog:
    # Change Log
    ## [2.5.1] - 2018-02-13
    ### Fixed
    - fix crash getting NPL of a different TiVo than the one with active downloads.
    ## [2.5.0] - 2018-02-01
    ### Changed
    - add new _ts_error_mode_ value **all** that saves all togo download attempts
    - refactor the pyTivo version references in the code and add the version to
      the info page
    - Update dependecies
        - mutagen (1.40)
    ## [2.4.0] - 2018-01-26
    ### Changed
    - config fields for customized togo file naming; _episode_fn_ &  _movie_fn_,
      see [togo/](./plugins/togo/ for more info
    - change logging priority of httpserver requests from info to debug to reduce
      noise when sending info priority messages to the console
    ## [2.3.0] - 2018-01-09
    Some testing on Windows 7 in addition to Linux
    ### Changed
    - Write a yaml sync error log file for every togo download
    - Default to using transport stream downloads
    - Update dependecies
        - mutagen (1.39)
        - pytz (2017.3)
        - tzlocal (1.5.1)
    - Add a section to the Readme about installing on MS Windows
    ### Added
    - Add some TiVo documentation so it's available in the future if needed.
    - Add some development features like a Makefile to help running pylint and
      other development tasks
    ## [2.2.1] - 2017-07-30
    ### Fixed
    - fix exception putting attempt number in filename
    - improve logging
    ## [2.2.0] - 2017-07-29
    ### Changed
    - Improve the logging during togo downloads
    - Implement new ShowInfo class to encapsulate most of the show metadata
    - Refactor download thread functionality
    - Update dependecies, add tzlocal
        - mutagen (1.38)
        - zeroconf (0.19.1)
        - tzlocal (1.4)
    ## [2.1.0] - 2017-07-18
    ### Changed
    - Incorporate Dan203's changes for his version PyTivo up through 1.6.7 except the
      pyInstaller and pyTivoTray which were more specifically for PyTivoDesktop and
      Windows & Mac not Linux.
        - Check transport stream (ts) downloads for sync errors
        - TivoDesktop togo file naming
        - support using tivolibre to decode the downloaded .tivo file
    - moved togo settings to their own section in pytivo.conf ([togo])
    ### Fixed
    - Implement thread safety for the togo download threads
    - Log not finding a binary (e.g. tivodecode) only once per run
    ### Added
    - new dependency
        - pytz (2017.2)
    ## [2.0.0] - 2017-06-20 (forked to
    Tested only on Linux
    ### Changed
    - Converted from Python 2 to **Python 3**
    - Remove local copies of packages, use latest versions from pip
        - zeroconf (0.19.0)
        - mutagen (1.37)
        - cheetah3 (3.0.0)
    - Format README with markdown
    - Various info added to the README
    - Prefix the episode title w/ the episode number when shown in a folder on the TiVo
    ### Added
    - requirements.txt file for use w/ pip to install dependencies
    ## [1.6.0] - prior to 2017-01-01 (from
    ### Added
    - All functionality of pyTivo up until this time. (I am not aware of any distinct
      versions or releases prior to this time. -mjl)
    If you try to use this fork and run into issues, let me know and I'll try to resolve them (no guarantees :))
    oregonman and aaronwt like this.
  3. kbgators

    kbgators New Member

    Dec 28, 2012
    Thank you for the work.
    I haven’t use pyTivo in a long time, since the ability auto-push to the TiVo was removed. Anyone ever get that working?
  4. fyodor

    fyodor Active Member

    Sep 19, 2006
    My understanding is that it is dependent on functionality in the Tivo/Tivo servers that doesn't exist anymore
  5. lpwcomp

    lpwcomp Well-Known Member

    May 6, 2002


    Yes, it used the TiVo servers to send the request to the TiVo. It was disabled (without notice) in August 2016.
  6. mlippert

    mlippert Active Member

    Apr 2, 2010
    You're welcome.

    As for push I was about to say exactly what @fyodor said, and @lpwcomp added even more details that I didn't know. (Thanks for that)
  7. Mar 2, 2018 #5967 of 6054

    oregonman Member

    Jul 1, 2002
    Portland OR
    I just recently lost my PC harddrive and with it my working pytivo setup, so I thought I would try your fork. Your github page says:
    The netifaces dependency requires Microsoft Visual C++ 14.0. Get it with "Microsoft Visual C++ Build Tools": Download the Visual C++ Build Tools (standalone C++ compiler, libraries and tools))

    That page has a download button, but it seems to have a lot of different links to a lot of different packages. Can you tell me specifically what I need to install? I'd prefer not to install a bunch of stuff I don't need. Thanks.
  8. Mar 2, 2018 #5968 of 6054

    mlippert Active Member

    Apr 2, 2010
    Gotcha, yeah that readme can use more work (yikes I just took another look, a lot more work if I expect people to install w/o handholding!), I'm happy to take feedback (like this) to improve it. I know it's got superfluous info on it right now. You're the 1st person I know of trying my fork (other than me).

    So The llnk above has a big purple box which is a link to: Downloads | IDE, Code, & Team Foundation Server | Visual Studio

    And yes I see a ton of other download links on that page. I'm pretty sure the one you want is titled "Build Tools for Visual Studio 2017" and the download link next to it is:

    That led to downloading vs_buildtools__246959477.1520043160.exe
    That doesn't exactly match the saved download file I have which is named visualcppbuildtools_full.exe but there is a possibility that I renamed it to make it more recognizable. I think it's more likely that MS changed the download somewhat.

    What I have installed is listed as "Microsoft Visual C++ Build Tools" version 14.0.25420.1 in Programs and Features.

    OK, I ran that downloaded vs_buildtools file and it brought up a Visual Studio installer which had an option to install several things, the only one I think you care to install is "Visual C++ build tools". I couldn't test further as I didn't want to overwrite my previous install.

    If you run into any other issues, please let me know.
    oregonman and kpeters59 like this.
  9. Mar 5, 2018 #5969 of 6054

    19972000muskrat Active Member

    Jan 2, 2008
    So how does one install the older version. I need to use it with pyTivo Desktop.
  10. Sep 9, 2018 #5970 of 6054

    saberman Member

    May 4, 2004
    When installing pyTivo from on Windows Pro x64 do we need the x64 or x32 versions of Python, FFmpeg and pywin? Logically it should be the x64 versions but logic has never been part of the Microsoft Windows world.
  11. Sep 9, 2018 #5971 of 6054

    wmcbrine Well-Known Mumbler

    Aug 2, 2003
    Either should work, as long as you're consistent. I'd go with the 64-bit versions.
  12. Soapm

    Soapm Active Member

    May 9, 2007
    Aurora, CO

    I'm trying to download shows from my Tivo Premier, I'm getting the audio but no video when I use pyTivo. It just sits when I check the TS box. I understood it was the format (I have xfinity) when I had this problem with my TivoHD but I'm now having the exact same problem with my Tivo Premier.

    Any suggestions how to fix this?
  13. mattack

    mattack Well-Known Member

    Apr 9, 2001
    you say 'it just sits'. Do you mean it hangs? if so, try kmttg.

    Though I have *ALSO* run into _some_ shows (CNN HD, as an example) that still end up with audio but no video EVEN in TS mode... but I successfully use kmttg to get other channels' shows in TS mode just fine..

    (I download broadcast channels and SD channels -- yes I still record various things in SD for space reasons -- in regular MPEG.. especially because TS downloads can have unpredictable glitches in them, due to faults on the Tivo's end IIRC.)
  14. Soapm

    Soapm Active Member

    May 9, 2007
    Aurora, CO
    I am trying KMTTG but having problems with it also, but by just sits I mean is stays "queued" and never starts transferring.
  15. mattack

    mattack Well-Known Member

    Apr 9, 2001
    That is very strange.. then I guess the last try is the built in web server in the Tivo directly.. but I don't know if you can get TS downloads that way... (Though I think that's 'all' kmttg does, is talk directly to the web server..)
  16. HerronScott

    HerronScott Well-Known Member

    Jan 1, 2002
    Staunton, VA
    Yes, you can with a Premiere or newer.

  17. Soapm

    Soapm Active Member

    May 9, 2007
    Aurora, CO
    I am revisiting all my settings, what do you guys suggest for mind server? I have but wondering if there's a better setting and what symptoms would I see if the setting is wrong (not working).

    Also, I have -threads 2 for ffmpeg. I have a quad core processor, do this help any?
  18. wmcbrine

    wmcbrine Well-Known Mumbler

    Aug 2, 2003
    Mind server is irrelevant now. It was used for Push, but Push is dead.

    I think modern FFmpeg automatically uses an optimal number of threads if you omit that option.
  19. Soapm

    Soapm Active Member

    May 9, 2007
    Aurora, CO
    Cool, you gave me two answers in one...

    1. I can remove those settings...

    2. They're not my problem...

  20. Soapm

    Soapm Active Member

    May 9, 2007
    Aurora, CO
    Weirdest thing, all I remember doing is removing those two settings and now I'm able to transfer shows from my TivoHD. I guess the config file just needed refreshing or something.

Share This Page

spam firewall