mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-07-31 03:50:06 -07:00
a few small fixes
This commit is contained in:
parent
0a9c8030e5
commit
4d69f85677
1 changed files with 7 additions and 6 deletions
|
@ -1,4 +1,4 @@
|
||||||
uimport sys
|
import sys
|
||||||
import urllib
|
import urllib
|
||||||
import os
|
import os
|
||||||
import shutil
|
import shutil
|
||||||
|
@ -46,17 +46,16 @@ def get_imdb(nzbName, dirName):
|
||||||
def get_movie_info(baseURL, imdbid, download_id):
|
def get_movie_info(baseURL, imdbid, download_id):
|
||||||
|
|
||||||
movie_id = ""
|
movie_id = ""
|
||||||
|
movie_status = None
|
||||||
|
release_status = None
|
||||||
if not imdbid and not download_id:
|
if not imdbid and not download_id:
|
||||||
return movie_id, imdbid, download_id, None, None
|
return movie_id, imdbid, download_id, movie_status, release_status
|
||||||
|
|
||||||
releaselist = []
|
releaselist = []
|
||||||
movieid = []
|
movieid = []
|
||||||
moviestatus = []
|
moviestatus = []
|
||||||
library = []
|
library = []
|
||||||
release = []
|
release = []
|
||||||
movie_status = None
|
|
||||||
release_status = None
|
|
||||||
offset = int(0)
|
offset = int(0)
|
||||||
while True:
|
while True:
|
||||||
url = baseURL + "media.list/?status=active&release_status=snatched&limit_offset=50," + str(offset)
|
url = baseURL + "media.list/?status=active&release_status=snatched&limit_offset=50," + str(offset)
|
||||||
|
@ -293,8 +292,10 @@ def process(dirName, nzbName=None, status=0, clientAgent = "manual", download_id
|
||||||
Logger.exception("Unable to delete folder %s", dirName)
|
Logger.exception("Unable to delete folder %s", dirName)
|
||||||
return 0 # success
|
return 0 # success
|
||||||
|
|
||||||
if nzbName == "Manual Run" or download_id == "none":
|
if nzbName == "Manual Run":
|
||||||
return 0 # success
|
return 0 # success
|
||||||
|
if not download_id:
|
||||||
|
return 1 # just to be sure TorrentToMedia doesn't start deleting files as we havent verified changed status.
|
||||||
|
|
||||||
# we will now check to see if CPS has finished renaming before returning to TorrentToMedia and unpausing.
|
# we will now check to see if CPS has finished renaming before returning to TorrentToMedia and unpausing.
|
||||||
socket.setdefaulttimeout(int(TimeOut)) #initialize socket timeout.
|
socket.setdefaulttimeout(int(TimeOut)) #initialize socket timeout.
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue