lpinner / yardwiz

YARDWiz - Yet Another Recording Downloader for the Wiz
Other
2 stars 0 forks source link

List recordings hangs part way through the list #43

Closed seanf closed 9 years ago

seanf commented 9 years ago

If I enable quick listing, the titles and dates are all listed, but when YARDWiz starts listing the details, it gets through about a dozen before hanging, always after the same entry. It just keeps saying "Connecting..." with the progress bar moving, but nothing else is ever loaded. At this point, "Delete" is greyed out on the context menu, and if I try to download anything, the actual download never starts.

If I disable quick listing, YARDWiz just lists the details of a dozen entries before hanging the same way.

I should probably mention that I deleted a large number of recordings using YARDWiz. (I can't re-index because my Beyonwiz's remote control functions no longer work. Network access is my only access.)

Edited YARDWiz debug log follows:

DEBUG __init__._ApplyConfig: YARDWiz 1.0.0.0 C:\Program Files (x86)\YARDWiz\yardwiz.exe win32
DEBUG __init__._ApplyConfig: .\getWizPnP.exe
DEBUG __init__._ApplyConfig: PATH
    C:\Program Files (x86)\VideoLAN\VLC
    C:\ProgramData\Oracle\Java\javapath
    C:\Program Files (x86)\NVIDIA Corporation\PhysX\Common
    C:\windows\system32
    C:\windows
    C:\windows\System32\Wbem
    C:\windows\System32\WindowsPowerShell\v1.0\
    C:\Program Files (x86)\Common Files\GTK\2.0\bin
    C:\Program Files (x86)\Git\cmd
    C:\Program Files (x86)\QuickTime\QTSystem
    C:\bin
    C:\Users\Sean\AppData\Roaming\Python\Scripts
    C:\Users\Sean\AppData\Roaming\cabal\bin
    D:\Program Files\nodejs\
    C:\Program Files (x86)\sbt\\bin
    C:\Program Files\Java\jdk1.8.0_40\bin
    D:\Ruby200-x64\bin
    C:\Program Files (x86)\clisp-2.49
    C:\Apps\apache-ant-1.9.2\bin
    C:\Apps\gradle\bin
    C:\Apps\apache-maven\bin
    C:\Apps\Python27
    C:\Apps\Python27\Scripts
    C:\Program Files (x86)\GnuWin32\bin
    C:\Program Files (x86)\Git\bin
    C:\Chocolatey\bin
    D:\Program Files\Boot2Docker for Windows
    C:\Program Files (x86)\SMLNJ\bin
    C:\Users\Sean\AppData\Roaming\npm
    C:\Program Files (x86)\sbt\bin
    C:\Program Files (x86)\EaseUS\Todo Backup\bin\x64\
    .
    C:\Program Files (x86)\YARDWiz
DEBUG __init__._ApplyConfig: Config:
  Settings
    cachedevice=True
    device=192.168.0.122:49152 beyonwiz
    autoconnect=True
    onselect=False
    lastdir=F:\Beyonwiz\Movies
    tsformat=True
    postdownloadcommand=# "C:\Program Files\Avidemux 2.6 - 64bits\avidemux.exe" %F #somecommand %F (filepath) and/or %D (directory) # comment
    vlcargs=--deinterlace-mode=mean --qt-minimal-view
    tempfile=True
    display_dateformat=%a, %d %b %Y %H:%M
    filename_dateformat=%Y-%m-%d
    confirmdelete=True
    quicklisting=False
    showtooltips=True
    retries=3
    delete=False
  getWizPnP
    delay=0.25
    wizpnptimeout=2
  Sounds
    playsounds=True
    downloadcomplete=C:\Program Files (x86)\YARDWiz\sounds\downloadcomplete.wav
  Window
    fade=True
    xsize=1920
    ysize=1046
    xmin=0
    ymin=0
  Debug
    debug=True
    logfile=c:\users\sean\appdata\local\temp\YARDWiz.20150509.003859.2039.log
DEBUG __init__._ApplyConfig: Devices="192.168.0.122:49152 beyonwiz"
DEBUG __init__._ApplyConfig: Devices="['192.168.0.122:49152 beyonwiz']"
DEBUG utilities.__init__: Adding new Device
DEBUG utilities.__init__: Device IP,Port,Name="192.168.0.122,49152,beyonwiz"
DEBUG utilities.__init__: Device display="beyonwiz (192.168.0.122:49152)"
DEBUG utilities.__init__: Device args="['-H', '192.168.0.122', '-p', '49152']"
DEBUG utilities.__init__: Device str="192.168.0.122:49152 beyonwiz"
DEBUG __init__._ApplyConfig: 192.168.0.122:49152 beyonwiz
DEBUG __init__._ApplyConfig: OrderedDict([('beyonwiz (192.168.0.122:49152)', <yardwizgui.utilities.Device object at 0x03238F10>)])
DEBUG __init__._ApplyConfig: [<yardwizgui.utilities.Device object at 0x03238F10>]
DEBUG __init__._ApplyConfig: Window size: xmin 0, ymin 0, xsize 1920, ysize 1046
DEBUG __init__._ApplyConfig: Window resolution: xres 1920, yres 1046
DEBUG __init__._ApplyConfig: CanSetTransparent: True
DEBUG __init__._ApplyConfig: VLC path: VLC
DEBUG __init__.cbxDevice_OnKillFocus: 192.168.0.122:49152 beyonwiz
DEBUG __init__.cbxDevice_OnKillFocus: OrderedDict([('beyonwiz (192.168.0.122:49152)', <yardwizgui.utilities.Device object at 0x03238F10>)])
DEBUG __init__.cbxDevice_OnKillFocus: [<yardwizgui.utilities.Device object at 0x03238F10>]
DEBUG __init__.cbxDevice_OnKillFocus: 192.168.0.122:49152 beyonwiz
DEBUG __init__.cbxDevice_OnKillFocus: OrderedDict([('beyonwiz (192.168.0.122:49152)', <yardwizgui.utilities.Device object at 0x03238F10>)])
DEBUG __init__.cbxDevice_OnKillFocus: [<yardwizgui.utilities.Device object at 0x03238F10>]
DEBUG __init__._Connect: Connecting to 192.168.0.122:49152 beyonwiz
DEBUG __init__._Log: Connecting to beyonwiz (192.168.0.122:49152)...
DEBUG utilities.subproc: getWizPnP.exe --all -v -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152 --wizpnpTimeout=2 --delay=0.25
DEBUG utilities.subproc: ['getWizPnP.exe', '--all', '-v', '-l', '--episode', '--index', '--sort=fatd', '-H', '192.168.0.122', '-p', '49152', '--wizpnpTimeout=2', '--delay=0.25']
DEBUG __init__._Log: The WizPnP server is online.
DEBUG utilities._listprograms: Connecting to beyonwiz (192.168.0.122:49152)
DEBUG utilities.subproc: getWizPnP.exe -vv --all -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152
DEBUG utilities.subproc: ['getWizPnP.exe', '-vv', '--all', '-l', '--episode', '--index', '--sort=fatd', '-H', '192.168.0.122', '-p', '49152']
DEBUG utilities._getinfo: Connecting to beyonwiz (192.168.0.122:49152)
DEBUG utilities._listprograms: 7 Digital: Air Crash Investigations/Choosing Sides (British Midland Flight 92)
DEBUG utilities._listprograms: Index name: recordings/Air Crash Investigations May.7.2015_23.8
DEBUG utilities._listprograms: Thu May  7 23:08:00 2015 - Fri May  8 00:30:01 2015
DEBUG utilities._listprograms: playtime:   82:01    recording size:   3969.0 MB    bit rate:   6.5 Mb/s
DEBUG utilities._listprograms: autoDelete: Never
DEBUG utilities._listprograms: 
DEBUG __init__._Log: Added Air Crash Investigations - Choosing Sides (British Midland Flight 92) - Thu, 07 May 2015 23:08
DEBUG utilities._getinfo: 7 Digital: Air Crash Investigations/Choosing Sides (British Midland Flight 92)
DEBUG utilities._getinfo: A risky manoeuvre extracted a tragic price when an emergency motorway
DEBUG utilities._getinfo: landing cost 47 lives and injured many more in the Kegworth Air
DEBUG utilities._getinfo: Disaster, which involved the British Midland Flight 92. (United
DEBUG utilities._getinfo: Kingdom, English)
DEBUG utilities._getinfo: Index name: recordings/Air Crash Investigations May.7.2015_23.8
DEBUG utilities._getinfo: Thu May  7 23:08:00 2015 - Fri May  8 00:30:01 2015
DEBUG utilities._getinfo: playtime:   82:01    recording size:   3969.0 MB    bit rate:   6.5 Mb/s
DEBUG utilities._getinfo: autoDelete: Never
DEBUG utilities._getinfo: 
DEBUG __init__._Log: Updated episode info for Air Crash Investigations - Choosing Sides (British Midland Flight 92).

(snip)

DEBUG __init__._Log: Added SlideShow - Fri, 20 Mar 2015 15:53
DEBUG utilities._listprograms: 7mate: SlideShow *AC3
DEBUG utilities._listprograms: Index name: recordings/SlideShow Mar.14.2015_1.23
DEBUG utilities._listprograms: Sat Mar 14 01:23:00 2015 - Sat Mar 14 03:50:01 2015
DEBUG utilities._listprograms: playtime:  147:01    recording size:   9127.9 MB    bit rate:   8.3 Mb/s
DEBUG utilities._listprograms: autoDelete: Never
DEBUG utilities._listprograms: 
DEBUG __init__._Log: Added SlideShow - Sat, 14 Mar 2015 01:23
DEBUG utilities._listprograms: 7mate: SlideShow *AC3
DEBUG utilities._listprograms: Index name: recordings/SlideShow Mar.13.2015_14.53
DEBUG utilities._listprograms: Fri Mar 13 14:53:01 2015 - Fri Mar 13 17:25:03 2015
DEBUG utilities._listprograms: playtime:  152:02    recording size:   9118.4 MB    bit rate:   8.0 Mb/s
DEBUG utilities._listprograms: autoDelete: Never
DEBUG utilities._listprograms: 
DEBUG __init__._Log: Added SlideShow - Fri, 13 Mar 2015 14:53

For what it's worth WizZilla gives lots of errors for the deleted shows like this:

ERROR: No data return for '<show name>'
Returned: <show name> Connecting to beyonwiz (192.168.0.122:49152)
lpinner commented 9 years ago

Sorry, my account defaulted to ignoring this repository, so I have only just seen this issue. Will look into it.

lpinner commented 9 years ago

Does running getWizPnP.exe from the commandline hang as well? "C:\Program Files (x86)\YARDWiz\getWizPnP.exe" -vv --all -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152

seanf commented 9 years ago

No, getWizPnp works. The deleted entries appear like this on stderr, without any delay:

The Checkout:idehdd/Recordings/ABC_Apr.30.2015_19.53+57142.71580.tvwiz:

header too small to be valid 0 < 81140

YARDWiz takes a little while to skip (silently) over each of the deleted entries, but eventually YARDWiz gets stuck at what must be this point:

Hawaii

Five-0:idehdd/Recordings/TEN_Digital_Mar.11.2015_22.33+57092.81180.tvwiz: header too small to be valid 0 < 81140

On 24 May 2015 at 07:43, lpinner notifications@github.com wrote:

Does running getWizPnP.exe from the commandline hang as well? "C:\Program Files (x86)\YARDWiz\getWizPnP.exe" -vv --all -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152

— Reply to this email directly or view it on GitHub https://github.com/lpinner/yardwiz/issues/43#issuecomment-104947069.

lpinner commented 9 years ago

If you look in the Windows task manager when it hangs, do you see a getWizPnP.exe process? If so, what happens if you kill the getWizPnP process?

I haven't been able to reproduce the hang, testing on Linux and Windows, but I've only got a handful of recordings deleted using YARDWiz/GetWizPnP. I've put a little workaround in that will allow you disable the fetching of program info when the quick listing option is enabled. Get it from this link.

https://bintray.com/lukepinnerau/generic/YARDWizDev/Development

It does mean that all you'll see is the basic dump from the Wiz's index.txt so deleted recordings will show up and you'll need to know which ones you deleted.

To use, in the tools->options menu, enable quick listing and disable extended info (next option below quick listing).

seanf commented 9 years ago

Using Process Explorer, I found 2 copies of getWizPnP.exe, each with a child process running getwizpnp.exe.

One group had this command line for both getWizPnP.exe and getwizpnp.exe: getWizPnP.exe --all -v -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152 --wizpnpTimeout=2 --delay=0.25

but the other group had this: getWizPnP.exe -vv --all -l --episode --index --sort=fatd -H 192.168.0.122 -p 49152

When I killed the child process getwizpnp.exe with the shorter command line (no timeout parameter), the parent must have exited, YARDWiz woke up and carried on with the rest of the list as if nothing had happened. On closer inspection, the remaining entries don't have episode descriptions, but everything else is fine, including the hiding of deletions.

I tried running both command lines manually at the same time, but I couldn't reproduce the problem that way.

Seeing the sheer amount of output on the console made me think - could it be that the stderr of getwizpnp.exe is exceeding the size of a buffer, causing a deadlock? I've had such problems when using Java's low level process handling; maybe this is the Python version. A bit like this? http://stackoverflow.com/a/2561918/14379

It looks like stderr just exceeds 4096 bytes, right about where the freeze happens.

On 27 May 2015 at 22:20, lpinner notifications@github.com wrote:

If you look in the Windows task manager when it hangs, do you see a getWizPnP.exe process? If so, what happens if you kill the getWizPnP process?

I haven't been able to reproduce the hang, testing on Linux and Windows, but I've only got a handful of recordings deleted using YARDWiz/GetWizPnP. I've put a little workaround in that will allow you disable the fetching of program info when the quick listing option is enabled. Get it from this link.

https://bintray.com/lukepinnerau/generic/YARDWizDev/Development

It does mean that all you'll see is the basic dump from the Wiz's index.txt so deleted recordings will show up and you'll need to know which ones you deleted.

To use, in the tools->options menu, enable quick listing and disable extended info (next option below quick listing).

— Reply to this email directly or view it on GitHub https://github.com/lpinner/yardwiz/issues/43#issuecomment-105887786.

lpinner commented 9 years ago

Yep, I think that’s it. I was able to artificially reproduce by filling the stderr buffer up. The above commit should fix it. Can you try the version at https://bintray.com/artifact/download/lukepinnerau/generic/YARDWiz-1.1dev-2-win32setup.zip

seanf commented 9 years ago

Working well for my machine, thanks Luke!

On 28 May 2015 at 07:05, lpinner notifications@github.com wrote:

Yep, I think that’s it. I was able to artificially reproduce by filling the stderr buffer up. The above commit should fix it. Can you try the version at https://bintray.com/artifact/download/lukepinnerau/generic/YARDWiz-1.1dev-2-win32setup.zip

— Reply to this email directly or view it on GitHub https://github.com/lpinner/yardwiz/issues/43#issuecomment-106075064.