From f0b7d1ef2b2e6068062996e01e9684628cdabb35 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Wed, 10 Jun 2015 10:40:43 +0200 Subject: Update plugins (2) --- module/plugins/hoster/SimplyPremiumCom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/hoster/SimplyPremiumCom.py') diff --git a/module/plugins/hoster/SimplyPremiumCom.py b/module/plugins/hoster/SimplyPremiumCom.py index b3f52bc8c..2ca900b0a 100644 --- a/module/plugins/hoster/SimplyPremiumCom.py +++ b/module/plugins/hoster/SimplyPremiumCom.py @@ -9,7 +9,7 @@ from module.plugins.internal.SimpleHoster import secondsToMidnight class SimplyPremiumCom(MultiHoster): __name__ = "SimplyPremiumCom" __type__ = "hoster" - __version__ = "0.08" + __version__ = "0.09" __pattern__ = r'https?://.+simply-premium\.com' __config__ = [("use_premium", "bool", "Use premium account if available", True)] -- cgit v1.2.3 From e4fb45b22d36595839e8f638a3f0a4669dba3e8d Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 21 Jun 2015 08:50:26 +0200 Subject: Spare code cosmetics (4) --- module/plugins/hoster/SimplyPremiumCom.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'module/plugins/hoster/SimplyPremiumCom.py') diff --git a/module/plugins/hoster/SimplyPremiumCom.py b/module/plugins/hoster/SimplyPremiumCom.py index 2ca900b0a..8ea121199 100644 --- a/module/plugins/hoster/SimplyPremiumCom.py +++ b/module/plugins/hoster/SimplyPremiumCom.py @@ -12,7 +12,8 @@ class SimplyPremiumCom(MultiHoster): __version__ = "0.09" __pattern__ = r'https?://.+simply-premium\.com' - __config__ = [("use_premium", "bool", "Use premium account if available", True)] + __config__ = [("use_premium" , "bool", "Use premium account if available" , True), + ("revertfailed", "bool", "Revert to standard download if fails", True)] __description__ = """Simply-Premium.com multi-hoster plugin""" __license__ = "GPLv3" -- cgit v1.2.3 From b1759bc440cd6013837697eb8de540914f693ffd Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 7 Jul 2015 01:23:55 +0200 Subject: No camelCase style anymore --- module/plugins/hoster/SimplyPremiumCom.py | 24 ++++++++++++------------ 1 file changed, 12 insertions(+), 12 deletions(-) (limited to 'module/plugins/hoster/SimplyPremiumCom.py') diff --git a/module/plugins/hoster/SimplyPremiumCom.py b/module/plugins/hoster/SimplyPremiumCom.py index 8ea121199..f726b0bf9 100644 --- a/module/plugins/hoster/SimplyPremiumCom.py +++ b/module/plugins/hoster/SimplyPremiumCom.py @@ -3,13 +3,13 @@ import re from module.plugins.internal.MultiHoster import MultiHoster, create_getInfo -from module.plugins.internal.SimpleHoster import secondsToMidnight +from module.plugins.internal.SimpleHoster import seconds_to_midnight class SimplyPremiumCom(MultiHoster): __name__ = "SimplyPremiumCom" __type__ = "hoster" - __version__ = "0.09" + __version__ = "0.10" __pattern__ = r'https?://.+simply-premium\.com' __config__ = [("use_premium" , "bool", "Use premium account if available" , True), @@ -21,10 +21,10 @@ class SimplyPremiumCom(MultiHoster): def setup(self): - self.chunkLimit = 16 + self.chunk_limit = 16 - def checkErrors(self): + def check_errors(self): if '0' in self.html or ( "You are not allowed to download from this host" in self.html and self.premium): self.account.relogin(self.user) @@ -34,30 +34,30 @@ class SimplyPremiumCom(MultiHoster): self.offline() elif "downloadlimit" in self.html: - self.logWarning(_("Reached maximum connctions")) + self.log_warning(_("Reached maximum connctions")) self.retry(5, 60, _("Reached maximum connctions")) elif "trafficlimit" in self.html: - self.logWarning(_("Reached daily limit for this host")) - self.retry(wait_time=secondsToMidnight(gmt=2), reason="Daily limit for this host reached") + self.log_warning(_("Reached daily limit for this host")) + self.retry(wait_time=seconds_to_midnight(gmt=2), reason="Daily limit for this host reached") elif "hostererror" in self.html: - self.logWarning(_("Hoster temporarily unavailable, waiting 1 minute and retry")) + self.log_warning(_("Hoster temporarily unavailable, waiting 1 minute and retry")) self.retry(5, 60, _("Hoster is temporarily unavailable")) - def handlePremium(self, pyfile): + def handle_premium(self, pyfile): for i in xrange(5): self.html = self.load("http://www.simply-premium.com/premium.php", get={'info': "", 'link': self.pyfile.url}) if self.html: - self.logDebug("JSON data: " + self.html) + self.log_debug("JSON data: " + self.html) break else: - self.logInfo(_("Unable to get API data, waiting 1 minute and retry")) + self.log_info(_("Unable to get API data, waiting 1 minute and retry")) self.retry(5, 60, _("Unable to get API data")) - self.checkErrors() + self.check_errors() try: self.pyfile.name = re.search(r'([^<]+)', self.html).group(1) -- cgit v1.2.3 From d38e830b7c0b3c6561a0072c74bbccb5fcdf4a61 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 19 Jul 2015 14:43:42 +0200 Subject: New __status__ magic key --- module/plugins/hoster/SimplyPremiumCom.py | 1 + 1 file changed, 1 insertion(+) (limited to 'module/plugins/hoster/SimplyPremiumCom.py') diff --git a/module/plugins/hoster/SimplyPremiumCom.py b/module/plugins/hoster/SimplyPremiumCom.py index f726b0bf9..afad1bb14 100644 --- a/module/plugins/hoster/SimplyPremiumCom.py +++ b/module/plugins/hoster/SimplyPremiumCom.py @@ -10,6 +10,7 @@ class SimplyPremiumCom(MultiHoster): __name__ = "SimplyPremiumCom" __type__ = "hoster" __version__ = "0.10" + __status__ = "stable" __pattern__ = r'https?://.+simply-premium\.com' __config__ = [("use_premium" , "bool", "Use premium account if available" , True), -- cgit v1.2.3 From 94d017cd2a5c1f194960827a8c7e46afc3682008 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Fri, 24 Jul 2015 06:55:49 +0200 Subject: Hotfixes (2) --- module/plugins/hoster/SimplyPremiumCom.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/hoster/SimplyPremiumCom.py') diff --git a/module/plugins/hoster/SimplyPremiumCom.py b/module/plugins/hoster/SimplyPremiumCom.py index afad1bb14..be1578bfb 100644 --- a/module/plugins/hoster/SimplyPremiumCom.py +++ b/module/plugins/hoster/SimplyPremiumCom.py @@ -10,7 +10,7 @@ class SimplyPremiumCom(MultiHoster): __name__ = "SimplyPremiumCom" __type__ = "hoster" __version__ = "0.10" - __status__ = "stable" + __status__ = "testing" __pattern__ = r'https?://.+simply-premium\.com' __config__ = [("use_premium" , "bool", "Use premium account if available" , True), -- cgit v1.2.3