summaryrefslogtreecommitdiffstats
path: root/pyLoadCore.py
diff options
context:
space:
mode:
authorGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-09-03 15:47:30 +0200
committerGravatar RaNaN <Mast3rRaNaN@hotmail.de> 2010-09-03 15:47:30 +0200
commite86be5d91ddc9836a9e641ff07a439bb33bbc801 (patch)
tree1ae3c56c526cc0e0779fdd9a14d0c2b916ca39f9 /pyLoadCore.py
parentlittle fixes (diff)
downloadpyload-e86be5d91ddc9836a9e641ff07a439bb33bbc801.tar.xz
netload prefetching fix
Diffstat (limited to 'pyLoadCore.py')
-rwxr-xr-xpyLoadCore.py15
1 files changed, 11 insertions, 4 deletions
diff --git a/pyLoadCore.py b/pyLoadCore.py
index 359064ba2..5d28c534e 100755
--- a/pyLoadCore.py
+++ b/pyLoadCore.py
@@ -200,11 +200,13 @@ class Core(object):
#@TODO refractor
self.check_install("Crypto", _("pycrypto to decode container files"))
- self.check_install("Image", _("Python Image Libary (PIL) for captcha reading"))
+ img = self.check_install("Image", _("Python Image Libary (PIL) for captcha reading"))
self.check_install("pycurl", _("pycurl to download any files"), True, True)
self.check_install("django", _("Django for webinterface"))
self.check_file("tmp", _("folder for temporary files"), True)
- #self.check_install("tesseract", _("tesseract for captcha reading"), False)
+ #tesser = self.check_install("tesseract", _("tesseract for captcha reading"), False)
+
+ self.captcha = img
self.check_file(self.config['general']['download_folder'], _("folder for downloads"), True)
self.check_file("links.txt", _("file for links"))
@@ -343,9 +345,14 @@ class Core(object):
else:
pipe = subprocess.PIPE
subprocess.Popen(check_name, stdout=pipe, stderr=pipe)
+
+ return True
except:
- self.log.info(_("Install %s") % legend)
- if essential: exit()
+ if essential:
+ self.log.info(_("Install %s") % legend)
+ exit()
+
+ return False
def check_file(self, check_names, description="", folder=False, empty=True, essential=False, quiet=False):
"""check wether needed files exists"""