Pre-Queue Script
Posted: December 6th, 2012, 2:27 pm
I wasn't 100% sure where to put this, but since it lives with post-processing....
I threw together a pre-queue script that will refuse (return 0) for duplicate episodes. (I just thew it together in VBScript for SABNZBD running on windows).
It works the first time it runs, but subsequently refuses everything. No matter what, the log says the pre-queue script has refused the file, even if when I manually run it it doesn't.
I examine the logs and if I run the script passing the parameters from the Pre-Queue call - the script works as expected.
It's really simple - if the name of the file is: "Robot Chicken S06E09 1080p WEB DL AAC2 0 H264 iT00NZ" the script will find the folder called "Robot Chicken" and then the Season folder (6) and then look for Episode 9.
My sorting is: Show Name\Season 1\Show Name - S01E05 - Episode Name [DTS].avi
So basically - under the Show Name folder - I can parse all sub files for "S06E09" and return 0 or 1.
Am I missing a step? Not terminating my script correctly?
Any suggestions are appreciated.
I threw together a pre-queue script that will refuse (return 0) for duplicate episodes. (I just thew it together in VBScript for SABNZBD running on windows).
It works the first time it runs, but subsequently refuses everything. No matter what, the log says the pre-queue script has refused the file, even if when I manually run it it doesn't.
I examine the logs and if I run the script passing the parameters from the Pre-Queue call - the script works as expected.
It's really simple - if the name of the file is: "Robot Chicken S06E09 1080p WEB DL AAC2 0 H264 iT00NZ" the script will find the folder called "Robot Chicken" and then the Season folder (6) and then look for Episode 9.
My sorting is: Show Name\Season 1\Show Name - S01E05 - Episode Name [DTS].avi
So basically - under the Show Name folder - I can parse all sub files for "S06E09" and return 0 or 1.
Am I missing a step? Not terminating my script correctly?
Any suggestions are appreciated.