mirror of
https://github.com/clinton-hall/nzbToMedia.git
synced 2025-08-19 21:03:14 -07:00
get label from deluge. Fixes #600
This commit is contained in:
parent
912e639c4f
commit
d050934a60
2 changed files with 5 additions and 3 deletions
|
@ -474,9 +474,9 @@ def parse_deluge(args):
|
||||||
# Deluge usage: call TorrentToMedia.py TORRENT_ID TORRENT_NAME TORRENT_DIR
|
# Deluge usage: call TorrentToMedia.py TORRENT_ID TORRENT_NAME TORRENT_DIR
|
||||||
inputDirectory = os.path.normpath(args[3])
|
inputDirectory = os.path.normpath(args[3])
|
||||||
inputName = args[2]
|
inputName = args[2]
|
||||||
inputCategory = '' # We dont have a category yet
|
|
||||||
inputHash = args[1]
|
inputHash = args[1]
|
||||||
inputID = args[1]
|
inputID = args[1]
|
||||||
|
inputCategory = nzbtomedia.TORRENT_CLASS.core.get_torrent_status(inputID, ['label']).get()['label']
|
||||||
return inputDirectory, inputName, inputCategory, inputHash, inputID
|
return inputDirectory, inputName, inputCategory, inputHash, inputID
|
||||||
|
|
||||||
|
|
||||||
|
@ -732,7 +732,6 @@ def create_torrent_class(clientAgent):
|
||||||
|
|
||||||
return tc
|
return tc
|
||||||
|
|
||||||
|
|
||||||
def pause_torrent(clientAgent, inputHash, inputID, inputName):
|
def pause_torrent(clientAgent, inputHash, inputID, inputName):
|
||||||
logger.debug("Stopping torrent %s in %s while processing" % (inputName, clientAgent))
|
logger.debug("Stopping torrent %s in %s while processing" % (inputName, clientAgent))
|
||||||
|
|
||||||
|
@ -745,7 +744,6 @@ def pause_torrent(clientAgent, inputHash, inputID, inputName):
|
||||||
|
|
||||||
time.sleep(5)
|
time.sleep(5)
|
||||||
|
|
||||||
|
|
||||||
def resume_torrent(clientAgent, inputHash, inputID, inputName):
|
def resume_torrent(clientAgent, inputHash, inputID, inputName):
|
||||||
logger.debug("Starting torrent %s in %s" % (inputName, clientAgent))
|
logger.debug("Starting torrent %s in %s" % (inputName, clientAgent))
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,6 @@
|
||||||
#! /usr/bin/env python2
|
#! /usr/bin/env python2
|
||||||
import os
|
import os
|
||||||
|
import sys
|
||||||
import datetime
|
import datetime
|
||||||
import re
|
import re
|
||||||
import nzbtomedia
|
import nzbtomedia
|
||||||
|
@ -11,6 +12,9 @@ from nzbtomedia.nzbToMediaUtil import get_downloadInfo, server_responding
|
||||||
# Initialize the config
|
# Initialize the config
|
||||||
nzbtomedia.initialize()
|
nzbtomedia.initialize()
|
||||||
|
|
||||||
|
#label = nzbtomedia.TORRENT_CLASS.core.get_torrent_status("f33a9c4b15cbd9170722d700069af86746817ade", ["label"]).get()['label']
|
||||||
|
#print label
|
||||||
|
|
||||||
if transcoder.isVideoGood(nzbtomedia.TEST_FILE, 0):
|
if transcoder.isVideoGood(nzbtomedia.TEST_FILE, 0):
|
||||||
print "FFPROBE Works"
|
print "FFPROBE Works"
|
||||||
else:
|
else:
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue