mirror of
https://github.com/evilhero/mylar
synced 2025-01-03 13:34:33 +00:00
FIX: Possible fix for 32P not honouring the auto-disable option when invoked, FIX: Annuals would not send notifications with the word annual in them, logging would indicate non-annual items were being post-processed/completed when in fact they were annuals, FIX: ComicTagger would not honour settings.ini file being used for specific settings (also requires usage of 0/1 instead of True/False)
This commit is contained in:
parent
bc5548238b
commit
021dc47fae
6 changed files with 35 additions and 26 deletions
|
@ -45,7 +45,7 @@ def ctmain():
|
|||
if opts.cv_api_key:
|
||||
if opts.cv_api_key != settings.cv_api_key:
|
||||
settings.cv_api_key = opts.cv_api_key
|
||||
settings.save()
|
||||
#settings.save()
|
||||
if opts.only_set_key:
|
||||
print("Key set")
|
||||
return
|
||||
|
|
|
@ -168,16 +168,16 @@ class ComicTaggerSettings:
|
|||
# see if it's in the path of unix user
|
||||
if utils.which("rar") is not None:
|
||||
self.rar_exe_path = utils.which("rar")
|
||||
if self.rar_exe_path != "":
|
||||
self.save()
|
||||
#if self.rar_exe_path != "":
|
||||
# self.save()
|
||||
|
||||
if self.unrar_exe_path == "":
|
||||
if platform.system() != "Windows":
|
||||
# see if it's in the path of unix user
|
||||
if utils.which("unrar") is not None:
|
||||
self.unrar_exe_path = utils.which("unrar")
|
||||
if self.unrar_exe_path != "":
|
||||
self.save()
|
||||
#if self.unrar_exe_path != "":
|
||||
# self.save()
|
||||
|
||||
# make sure unrar/rar programs are now in the path for the UnRAR class to
|
||||
# use
|
||||
|
|
|
@ -557,6 +557,7 @@ class PostProcessor(object):
|
|||
annchk = "yes"
|
||||
issuechk = myDB.select("SELECT * from annuals WHERE ComicID=? AND Int_IssueNumber=?", [cs['ComicID'], fcdigit])
|
||||
else:
|
||||
annchk = "no"
|
||||
fcdigit = helpers.issuedigits(temploc)
|
||||
issuechk = myDB.select("SELECT * from issues WHERE ComicID=? AND Int_IssueNumber=?", [cs['ComicID'], fcdigit])
|
||||
|
||||
|
@ -671,12 +672,18 @@ class PostProcessor(object):
|
|||
clocation = watchmatch['comiclocation']
|
||||
else:
|
||||
clocation = os.path.join(watchmatch['comiclocation'],helpers.conversion(watchmatch['comicfilename']))
|
||||
if 'Annual' in isc['ComicName']:
|
||||
annualtype = 'Annual'
|
||||
elif 'Special' in isc['ComicName']:
|
||||
annualtype = 'Special'
|
||||
annualtype = None
|
||||
if annchk == 'yes':
|
||||
if 'Annual' in isc['ReleaseComicName']:
|
||||
annualtype = 'Annual'
|
||||
elif 'Special' in isc['ReleaseComicName']:
|
||||
annualtype = 'Special'
|
||||
else:
|
||||
annualtype = None
|
||||
if 'Annual' in isc['ComicName']:
|
||||
annualtype = 'Annual'
|
||||
elif 'Special' in isc['ComicName']:
|
||||
annualtype = 'Special'
|
||||
|
||||
manual_list.append({"ComicLocation": clocation,
|
||||
"ComicID": cs['ComicID'],
|
||||
"IssueID": isc['IssueID'],
|
||||
|
@ -2270,13 +2277,14 @@ class PostProcessor(object):
|
|||
updatetable = 'issues'
|
||||
else:
|
||||
updater.foundsearch(comicid, issueid, mode='want_ann', down=downtype, module=module, crc=crcvalue)
|
||||
if 'annual' in issuenzb['ComicName'].lower(): #series.lower():
|
||||
if 'annual' in issuenzb['ReleaseComicName'].lower(): #series.lower():
|
||||
dispiss = 'Annual #%s' % issuenumOG
|
||||
elif 'special' in issuenzb['ComicName'].lower():
|
||||
elif 'special' in issuenzb['ReleaseComicName'].lower():
|
||||
dispiss = 'Special #%s' % issuenumOG
|
||||
else:
|
||||
dispiss = '#%s' % issuenumOG
|
||||
updatetable = 'annuals'
|
||||
logger.fdebug('[annchk:%s] issue to update: %s' % (annchk, dispiss))
|
||||
|
||||
#new method for updating status after pp
|
||||
if os.path.isfile(dst):
|
||||
|
|
|
@ -51,6 +51,7 @@ class Readinglist(object):
|
|||
logger.error(self.module + ' Cannot locate IssueID - aborting..')
|
||||
return
|
||||
else:
|
||||
logger.fdebug('%s Successfully found annual for %s' % (self.module, readlist['ComicID']))
|
||||
annualize = True
|
||||
comicinfo = myDB.selectone("SELECT * from comics where ComicID=?", [readlist['ComicID']]).fetchone()
|
||||
logger.info(self.module + ' Attempting to add issueid ' + readlist['IssueID'])
|
||||
|
@ -71,19 +72,19 @@ class Readinglist(object):
|
|||
|
||||
if not locpath is None:
|
||||
comicissue = readlist['Issue_Number']
|
||||
comicname = comicinfo['ComicName']
|
||||
if annualize is True:
|
||||
comicname = readlist['ReleaseComicName']
|
||||
else:
|
||||
comicname = comicinfo['ComicName']
|
||||
dspinfo = comicname + ' #' + comicissue
|
||||
if annualize:
|
||||
if mylar.CONFIG.ANNUALS_ON:
|
||||
if 'annual' in readlist['ComicName'].lower():
|
||||
if annualize is True:
|
||||
if mylar.CONFIG.ANNUALS_ON is True:
|
||||
dspinfo = comicname + ' #' + readlist['Issue_Number']
|
||||
if 'annual' in comicname.lower():
|
||||
comicissue = 'Annual ' + readlist['Issue_Number']
|
||||
dspinfo = comicname + ' Annual #' + readlist['Issue_Number']
|
||||
elif 'special' in readlist['ComicName'].lower():
|
||||
elif 'special' in comicname.lower():
|
||||
comicissue = 'Special ' + readlist['Issue_Number']
|
||||
dspinfo = comicname + ' Special #' + readlist['Issue_Number']
|
||||
else:
|
||||
comicname = comicinfo['ComicName'] + ' Annual'
|
||||
dspinfo = comicname + ' #' + comicissue
|
||||
|
||||
ctrlval = {"IssueID": self.IssueID}
|
||||
newval = {"DateAdded": helpers.today(),
|
||||
"Status": "Added",
|
||||
|
|
|
@ -56,7 +56,7 @@ class tehMain():
|
|||
logger.info('[RSS-FEEDS] Initiating Torrent RSS Feed Check on Demonoid / WorldWideTorrents.')
|
||||
#rsscheck.torrents(pickfeed='3') #TP.SE RSS Check (has to be page-parsed)
|
||||
rsscheck.torrents(pickfeed='Public') #TPSE = DEM RSS Check + WWT RSS Check
|
||||
if mylar.CONFIG.ENABLE_32P:
|
||||
if mylar.CONFIG.ENABLE_32P is True:
|
||||
logger.info('[RSS-FEEDS] Initiating Torrent RSS Feed Check on 32P.')
|
||||
if mylar.CONFIG.MODE_32P == 0:
|
||||
logger.fdebug('[RSS-FEEDS] 32P mode set to Legacy mode. Monitoring New Releases feed only.')
|
||||
|
@ -75,7 +75,7 @@ class tehMain():
|
|||
if feedinfo != "disable":
|
||||
pass
|
||||
else:
|
||||
mylar.CONFIG.ENABLE_32P = 0
|
||||
mylar.CONFIG.ENABLE_32P = False
|
||||
#mylar.config_write()
|
||||
else:
|
||||
feedinfo = mylar.FEEDINFO_32P
|
||||
|
|
|
@ -76,10 +76,10 @@ def search_init(ComicName, IssueNumber, ComicYear, SeriesYear, Publisher, IssueD
|
|||
logger.info("Annual/Special issue search detected. Appending to issue #")
|
||||
#anything for mode other than None indicates an annual.
|
||||
if all(['annual' not in ComicName.lower(), 'special' not in ComicName.lower()]):
|
||||
ComicName = ComicName + " annual"
|
||||
ComicName = ComicName + " Annual"
|
||||
|
||||
if all([AlternateSearch is not None, AlternateSearch != "None", 'special' not in ComicName.lower()]):
|
||||
AlternateSearch = AlternateSearch + " annual"
|
||||
AlternateSearch = AlternateSearch + " Annual"
|
||||
|
||||
if mode == 'pullwant' or IssueID is None:
|
||||
#one-off the download.
|
||||
|
|
Loading…
Reference in a new issue