Fixed issues in the nzbTo* scripts with manual runs not properly sending the categories to be processed.

Fixed issue in TorrentToMedia with noFlatten variable for HeadPhones.

Changed name of function get_categories to get_sections in nzbToMediaUtil.

Added code in get_dirnames to properly return back the directory could not find anything to process in.
This commit is contained in:
echel0n 2014-04-05 20:56:12 -07:00
commit c3410fba8f
10 changed files with 70 additions and 72 deletions

View file

@ -89,7 +89,7 @@ else:
sys.exit(-1)
# mylar category
categories = config.get_categories(["Mylar"])
sections = config.get_sections(["Mylar"])
WakeUp()
@ -171,13 +171,13 @@ else:
Logger.warn("MAIN: Invalid number of arguments received from client.")
Logger.info("MAIN: Running autoProcessComics as a manual run...")
for section, category in categories.items():
for dirName in get_dirnames(section, category):
Logger.info("MAIN: Calling " + section + ":" + category + " to post-process: %s", dirName)
results = autoProcessComics().processEpisode(dirName, dirName, 0)
if results != 0:
result = 1
Logger.info("MAIN: A problem was reported in the autoProcessComics script.")
for section, categories in sections.items():
for category in categories:
dirNames = get_dirnames(section, category)
for dirName in dirNames:
Logger.info("MAIN: Calling " + section + ":" + category + " to post-process: %s", dirName)
results = autoProcessComics().processEpisode(dirName, dirName, 0, inputCategory=category)
if results != 0:result = results
if result == 0:
Logger.info("MAIN: The autoProcessComics script completed successfully.")