1
0
Fork 0
mirror of https://github.com/evilhero/mylar synced 2024-12-23 08:12:41 +00:00

FIX:(#141) Attempted fix to accomodate the '//' issues with windows paths, FIX: Custom_Exceptions error on Ultron EC adding in a title with a ',' - will add comicname to csv now

This commit is contained in:
evilhero 2013-01-29 04:02:23 -05:00
parent 1072a51f0c
commit 4eb71abefa
3 changed files with 13 additions and 6 deletions

View file

@ -82,7 +82,7 @@
</table>
<form action="error_change" method="GET">
<input type="hidden" name="comicid" value=${comicid}>
<inptu type="hidden" name="comicname" value=${comicname}>
<input type="hidden" name="comicname" value=${comicname |u}>
<div><br/>
<label><center><strong>Didn't get it right? Enter what it should be (or the GCD-ID) here:</strong></label></center>
<center><input type="text" name="errorgcd" size="30"><input type="submit" value="Update"/></center>

View file

@ -92,7 +92,7 @@ class PostProcessor(object):
self._log("initiating pre script detection.", logger.DEBUG)
self._log("mylar.PRE_SCRIPTS : " + mylar.PRE_SCRIPTS, logger.DEBUG)
# for currentScriptName in mylar.PRE_SCRIPTS:
currentScriptName = mylar.PRE_SCRIPTS
currentScriptName = str(mylar.PRE_SCRIPTS).decode("string_escape")
self._log("pre script detected...enabling: " + str(currentScriptName), logger.DEBUG)
# generate a safe command line string to execute the script and provide all the parameters
script_cmd = shlex.split(currentScriptName) + [str(nzb_name), str(nzb_folder), str(seriesmetadata)]
@ -117,7 +117,7 @@ class PostProcessor(object):
self._log("initiating extra script detection.", logger.DEBUG)
self._log("mylar.EXTRA_SCRIPTS : " + mylar.EXTRA_SCRIPTS, logger.DEBUG)
# for curScriptName in mylar.EXTRA_SCRIPTS:
curScriptName = mylar.EXTRA_SCRIPTS
curScriptName = str(mylar.EXTRA_SCRIPTS).decode("string_escape")
self._log("extra script detected...enabling: " + str(curScriptName), logger.DEBUG)
# generate a safe command line string to execute the script and provide all the parameters
script_cmd = shlex.split(curScriptName) + [str(nzb_name), str(nzb_folder), str(filen), str(folderp), str(seriesmetadata)]

View file

@ -274,6 +274,7 @@ class WebInterface(object):
logger.info(u"Deleting all traces of Comic: " + str(ComicName))
myDB.action('DELETE from comics WHERE ComicID=?', [ComicID])
myDB.action('DELETE from issues WHERE ComicID=?', [ComicID])
myDB.action('DELETE from upcoming WHERE ComicID=?' [ComicID])
raise cherrypy.HTTPRedirect("home")
deleteArtist.exposed = True
@ -728,11 +729,17 @@ class WebInterface(object):
return serve_template(templatename="config.html", title="Settings", config=config)
config.exposed = True
def error_change(self, comicid, errorgcd):
def error_change(self, comicid, errorgcd, comicname):
# if comicname contains a "," it will break the exceptions import.
import urllib
b = urllib.unquote_plus(comicname)
cname = b.decode("utf-8")
cname = re.sub("\,", "", cname)
if errorgcd[:5].isdigit():
print ("GCD-ID detected : " + str(errorgcd)[:5])
print ("I'm assuming you know what you're doing - going to force-match.")
self.from_Exceptions(comicid=comicid,gcdid=errorgcd)
print ("I'm assuming you know what you're doing - going to force-match for " + cname.encode("utf-8"))
self.from_Exceptions(comicid=comicid,gcdid=errorgcd,comicname=cname)
else:
print ("Assuming rewording of Comic - adjusting to : " + str(errorgcd))
Err_Info = mylar.cv.getComic(comicid,'comic')