diff options
author | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-08-30 16:09:09 +0200 |
---|---|---|
committer | RaNaN <Mast3rRaNaN@hotmail.de> | 2010-08-30 16:09:09 +0200 |
commit | 301ac21f2a4b6032d05fba362d167bf182404ee6 (patch) | |
tree | 71def1385a5c35d53994e95fac074b91d0eeafc5 /module | |
parent | encoding fixes (diff) | |
download | pyload-301ac21f2a4b6032d05fba362d167bf182404ee6.tar.xz |
little fixes
Diffstat (limited to 'module')
-rw-r--r-- | module/PluginThread.py | 1 | ||||
-rw-r--r-- | module/network/XdccRequest.py | 2 | ||||
-rw-r--r-- | module/plugins/crypter/SerienjunkiesOrg.py | 4 | ||||
-rw-r--r-- | module/plugins/hooks/ClickAndLoad.py | 2 | ||||
-rw-r--r-- | module/plugins/hooks/ExternalScripts.py | 2 | ||||
-rw-r--r-- | module/plugins/hooks/XMPPInterface.py | 11 | ||||
-rw-r--r-- | module/plugins/hoster/PornhostCom.py | 2 | ||||
-rw-r--r-- | module/plugins/hoster/PornhubCom.py | 2 | ||||
-rw-r--r-- | module/plugins/hoster/RapidshareCom.py | 3 | ||||
-rw-r--r-- | module/plugins/hoster/RedtubeCom.py | 2 | ||||
-rw-r--r-- | module/plugins/hoster/ShareCx.py | 2 | ||||
-rw-r--r-- | module/plugins/hoster/ShareonlineBiz.py | 4 | ||||
-rw-r--r-- | module/plugins/hoster/UploadedTo.py | 3 | ||||
-rw-r--r-- | module/setup.py | 2 |
14 files changed, 12 insertions, 30 deletions
diff --git a/module/PluginThread.py b/module/PluginThread.py index 005dedd99..aaa127d04 100644 --- a/module/PluginThread.py +++ b/module/PluginThread.py @@ -25,7 +25,6 @@ from time import strftime from traceback import print_exc, format_exc from pprint import pformat from sys import exc_info -from types import InstanceType from types import MethodType from module.plugins.Plugin import Abort diff --git a/module/network/XdccRequest.py b/module/network/XdccRequest.py index e6d714b25..28aee262e 100644 --- a/module/network/XdccRequest.py +++ b/module/network/XdccRequest.py @@ -25,7 +25,7 @@ import time import socket
from select import select
import re
-from os import sep, rename, stat
+from os import rename
from os.path import exists
import struct
diff --git a/module/plugins/crypter/SerienjunkiesOrg.py b/module/plugins/crypter/SerienjunkiesOrg.py index 6a7d976ab..cfd505db8 100644 --- a/module/plugins/crypter/SerienjunkiesOrg.py +++ b/module/plugins/crypter/SerienjunkiesOrg.py @@ -5,7 +5,6 @@ import re from module.plugins.Crypter import Crypter from module.BeautifulSoup import BeautifulSoup from module.unescape import unescape -from module.plugins.Plugin import Fail class SerienjunkiesOrg(Crypter): __name__ = "SerienjunkiesOrg" @@ -135,8 +134,7 @@ class SerienjunkiesOrg(Crypter): form = soup.find("form", attrs={"action":re.compile("^http://serienjunkies.org")}) captchaTag = form.find(attrs={"src":re.compile("^/safe/secure/")}) captchaUrl = "http://serienjunkies.org"+captchaTag["src"] - captchaData = self.req.load(str(captchaUrl)) - result = self.waitForCaptcha(captchaData, "png") + result = self.decryptCaptcha(str(captchaUrl)) url = form["action"] sinp = form.find(attrs={"name":"s"}) diff --git a/module/plugins/hooks/ClickAndLoad.py b/module/plugins/hooks/ClickAndLoad.py index b9824b863..fcbb27c21 100644 --- a/module/plugins/hooks/ClickAndLoad.py +++ b/module/plugins/hooks/ClickAndLoad.py @@ -43,7 +43,7 @@ class ClickAndLoad(Hook): thread.start_new_thread(proxy, (ip, self.port, 9666)) except: - self.logger.error("ClickAndLoad port already in use.") + self.log.error("ClickAndLoad port already in use.") def proxy(*settings): diff --git a/module/plugins/hooks/ExternalScripts.py b/module/plugins/hooks/ExternalScripts.py index a3ed2f168..111b60d22 100644 --- a/module/plugins/hooks/ExternalScripts.py +++ b/module/plugins/hooks/ExternalScripts.py @@ -20,7 +20,7 @@ from module.plugins.Hook import Hook import subprocess -from os import listdir, sep +from os import listdir from os.path import join import sys diff --git a/module/plugins/hooks/XMPPInterface.py b/module/plugins/hooks/XMPPInterface.py index bfd60d271..b2d8f301b 100644 --- a/module/plugins/hooks/XMPPInterface.py +++ b/module/plugins/hooks/XMPPInterface.py @@ -18,20 +18,11 @@ @interface-version: 0.2 """ -import socket -import sys -from threading import Thread -import time -from time import sleep -from traceback import print_exc - -from pyxmpp.all import JID,Iq,Presence,Message,StreamError +from pyxmpp.all import JID,Message from pyxmpp.jabber.client import JabberClient from pyxmpp.interface import implements from pyxmpp.interfaces import * -from pyxmpp.streamtls import TLSSettings -from module.plugins.Hook import Hook from module.plugins.hooks.IRCInterface import IRCInterface class XMPPInterface(IRCInterface, JabberClient): diff --git a/module/plugins/hoster/PornhostCom.py b/module/plugins/hoster/PornhostCom.py index 7a969f7f7..a4124c4a4 100644 --- a/module/plugins/hoster/PornhostCom.py +++ b/module/plugins/hoster/PornhostCom.py @@ -16,7 +16,7 @@ class PornhostCom(Hoster): def process(self, pyfile):
self.download_html()
if not self.file_exists():
- offline()
+ self.offline()
pyfile.name = self.get_file_name()
self.download(self.get_file_url())
diff --git a/module/plugins/hoster/PornhubCom.py b/module/plugins/hoster/PornhubCom.py index abc489e30..2df7ba452 100644 --- a/module/plugins/hoster/PornhubCom.py +++ b/module/plugins/hoster/PornhubCom.py @@ -16,7 +16,7 @@ class PornhubCom(Hoster): def process(self, pyfile):
self.download_html()
if not self.file_exists():
- offline()
+ self.offline()
pyfile.name = self.get_file_name()
self.download(self.get_file_url())
diff --git a/module/plugins/hoster/RapidshareCom.py b/module/plugins/hoster/RapidshareCom.py index 844d716ed..3dfc6d465 100644 --- a/module/plugins/hoster/RapidshareCom.py +++ b/module/plugins/hoster/RapidshareCom.py @@ -7,7 +7,6 @@ from time import time from module.network.Request import getURL from module.plugins.Hoster import Hoster -import hashlib def getInfo(urls): @@ -73,7 +72,7 @@ class RapidshareCom(Hoster): self.log.debug(_("%(name)s: Use Premium Account (%(left)sGB left)") % { "name" : self.__name__, "left": info["trafficleft"]/1000/1000 }) if self.api_data["size"] / 1024 > info["trafficleft"]: self.log.info(_("%s: Not enough traffic left" % self.__name__)) - self.resetAcount() + #self.resetAcount() #@TODO implement else: self.url = self.api_data["mirror"] return True diff --git a/module/plugins/hoster/RedtubeCom.py b/module/plugins/hoster/RedtubeCom.py index 748ab04f0..9ffafd905 100644 --- a/module/plugins/hoster/RedtubeCom.py +++ b/module/plugins/hoster/RedtubeCom.py @@ -17,7 +17,7 @@ class RedtubeCom(Hoster): def process(self, pyfile):
self.download_html()
if not self.file_exists():
- offline()
+ self.offline()
pyfile.name = self.get_file_name()
self.download(self.get_file_url())
diff --git a/module/plugins/hoster/ShareCx.py b/module/plugins/hoster/ShareCx.py index 63a51eab7..adebb1c77 100644 --- a/module/plugins/hoster/ShareCx.py +++ b/module/plugins/hoster/ShareCx.py @@ -50,7 +50,7 @@ class ShareCx(Hoster): self.pyfile = pyfile
self.download_html()
if not self.file_exists():
- offline()
+ self.offline()
pyfile.name = self.get_file_name()
self.doDownload()
diff --git a/module/plugins/hoster/ShareonlineBiz.py b/module/plugins/hoster/ShareonlineBiz.py index c10bf357c..5b1d12f66 100644 --- a/module/plugins/hoster/ShareonlineBiz.py +++ b/module/plugins/hoster/ShareonlineBiz.py @@ -1,11 +1,7 @@ #!/usr/bin/env python # -*- coding: utf-8 -*- -import os -import os.path import re -import tempfile -from time import time from base64 import b64decode import hashlib import random diff --git a/module/plugins/hoster/UploadedTo.py b/module/plugins/hoster/UploadedTo.py index b0c3486e3..f04e97531 100644 --- a/module/plugins/hoster/UploadedTo.py +++ b/module/plugins/hoster/UploadedTo.py @@ -5,7 +5,6 @@ from time import time from module.plugins.Hoster import Hoster from module.network.Request import getURL from module.plugins.Plugin import chunks -import hashlib def getInfo(urls): pattern = re.compile(UploadedTo.__pattern__) @@ -70,7 +69,7 @@ class UploadedTo(Hoster): self.log.debug(_("%(name)s: Use Premium Account (%(left)sGB left)") % {"name" :self.__name__, "left" : info["trafficleft"]/1024/1024}) if self.api_data["size"]/1024 > info["trafficleft"]: self.log.info(_("%s: Not enough traffic left" % self.__name__)) - self.resetAcount() + #self.resetAcount() #@TODO implement else: self.url = self.get_file_url() self.pyfile.name = self.get_file_name() diff --git a/module/setup.py b/module/setup.py index 937d7d91d..c6c83e95a 100644 --- a/module/setup.py +++ b/module/setup.py @@ -46,7 +46,7 @@ class Setup(): def start(self): - lang = self.ask("Choose your Language / Wähle deine Sprache", "en", ["en", "de"]) + lang = self.ask(u"Choose your Language / Wähle deine Sprache", "en", ["en", "de"]) translation = gettext.translation("setup", join(self.path, "locale"), languages=[lang]) translation.install(True) |