From 0e1ef9bc01579328e17e79416fa3c1c7b77adcc8 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Mon, 8 Jun 2015 06:08:01 +0200 Subject: Update everything --- module/plugins/accounts/EuroshareEu.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index db4539e2e..b0e87136f 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -3,13 +3,13 @@ import re import time -from module.plugins.Account import Account +from module.plugins.internal.Account import Account class EuroshareEu(Account): __name__ = "EuroshareEu" __type__ = "account" - __version__ = "0.02" + __version__ = "0.03" __description__ = """Euroshare.eu account plugin""" __license__ = "GPLv3" -- cgit v1.2.3 From 2efb23c40c2a77896d5fabf29af677aec9c6bd45 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Mon, 15 Jun 2015 07:01:02 +0200 Subject: [PremiumizeMe] Premium account fixup --- module/plugins/accounts/EuroshareEu.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index b0e87136f..0568b9c4f 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -22,7 +22,8 @@ class EuroshareEu(Account): m = re.search('id="input_expire_date" value="(\d+\.\d+\.\d+ \d+:\d+)"', html) if m is None: - premium, validuntil = False, -1 + premium = False + validuntil = -1 else: premium = True validuntil = time.mktime(time.strptime(m.group(1), "%d.%m.%Y %H:%M")) -- cgit v1.2.3 From c1764e2fea0bb05164c83a876e8cd58b97f58f25 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Tue, 16 Jun 2015 17:31:38 +0200 Subject: Update all --- module/plugins/accounts/EuroshareEu.py | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 0568b9c4f..4af9803b7 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -18,7 +18,7 @@ class EuroshareEu(Account): def loadAccountInfo(self, user, req): self.relogin(user) - html = req.load("http://euroshare.eu/customer-zone/settings/") + html = self.load("http://euroshare.eu/customer-zone/settings/", req=req) m = re.search('id="input_expire_date" value="(\d+\.\d+\.\d+ \d+:\d+)"', html) if m is None: @@ -32,11 +32,10 @@ class EuroshareEu(Account): def login(self, user, data, req): - html = req.load('http://euroshare.eu/customer-zone/login/', + html = self.load('http://euroshare.eu/customer-zone/login/', post={"trvale": "1", "login": user, - "password": data['password']}, - decode=True) + "password": data['password']}, req=req) if u">Nesprávne prihlasovacie meno alebo heslo" in html: self.wrongPassword() -- 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/accounts/EuroshareEu.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 4af9803b7..ffe30d02f 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -9,14 +9,14 @@ from module.plugins.internal.Account import Account class EuroshareEu(Account): __name__ = "EuroshareEu" __type__ = "account" - __version__ = "0.03" + __version__ = "0.04" __description__ = """Euroshare.eu account plugin""" __license__ = "GPLv3" __authors__ = [("zoidberg", "zoidberg@mujmail.cz")] - def loadAccountInfo(self, user, req): + def load_account_info(self, user, req): self.relogin(user) html = self.load("http://euroshare.eu/customer-zone/settings/", req=req) @@ -38,4 +38,4 @@ class EuroshareEu(Account): "password": data['password']}, req=req) if u">Nesprávne prihlasovacie meno alebo heslo" in html: - self.wrongPassword() + self.wrong_password() -- cgit v1.2.3 From d2e2b127651a5a44b56337eb6d9ca246c97a208a Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Fri, 17 Jul 2015 03:03:26 +0200 Subject: Spare fixes and code cosmetics --- module/plugins/accounts/EuroshareEu.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index ffe30d02f..5d909b789 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -33,9 +33,10 @@ class EuroshareEu(Account): def login(self, user, data, req): html = self.load('http://euroshare.eu/customer-zone/login/', - post={"trvale": "1", - "login": user, - "password": data['password']}, req=req) + post={"trvale" : "1", + "login" : user, + "password": data['password']}, + req=req) if u">Nesprávne prihlasovacie meno alebo heslo" in html: self.wrong_password() -- cgit v1.2.3 From 1f5a55ae2133a782bdcca334ecbcdbde50dbcf99 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Fri, 17 Jul 2015 15:29:48 +0200 Subject: No more need to use the req argument when call load method --- module/plugins/accounts/EuroshareEu.py | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 5d909b789..6317ea1b2 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -18,7 +18,7 @@ class EuroshareEu(Account): def load_account_info(self, user, req): self.relogin(user) - html = self.load("http://euroshare.eu/customer-zone/settings/", req=req) + html = self.load("http://euroshare.eu/customer-zone/settings/") m = re.search('id="input_expire_date" value="(\d+\.\d+\.\d+ \d+:\d+)"', html) if m is None: @@ -35,8 +35,7 @@ class EuroshareEu(Account): html = self.load('http://euroshare.eu/customer-zone/login/', post={"trvale" : "1", "login" : user, - "password": data['password']}, - req=req) + "password": data['password']}) if u">Nesprávne prihlasovacie meno alebo heslo" in html: self.wrong_password() -- cgit v1.2.3 From ff9383bfe06d14d23bc0ed6af79aa8967965d078 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sun, 19 Jul 2015 10:59:52 +0200 Subject: Code cosmetics (3) --- module/plugins/accounts/EuroshareEu.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 6317ea1b2..f39577fbd 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -28,14 +28,14 @@ class EuroshareEu(Account): premium = True validuntil = time.mktime(time.strptime(m.group(1), "%d.%m.%Y %H:%M")) - return {"validuntil": validuntil, "trafficleft": -1, "premium": premium} + return {'validuntil': validuntil, 'trafficleft': -1, 'premium': premium} def login(self, user, data, req): html = self.load('http://euroshare.eu/customer-zone/login/', - post={"trvale" : "1", - "login" : user, - "password": data['password']}) + post={'trvale' : "1", + 'login' : user, + 'password': data['password']}) if u">Nesprávne prihlasovacie meno alebo heslo" in html: self.wrong_password() -- 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/accounts/EuroshareEu.py | 1 + 1 file changed, 1 insertion(+) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index f39577fbd..884994f71 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -10,6 +10,7 @@ class EuroshareEu(Account): __name__ = "EuroshareEu" __type__ = "account" __version__ = "0.04" + __status__ = "stable" __description__ = """Euroshare.eu account plugin""" __license__ = "GPLv3" -- 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/accounts/EuroshareEu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 884994f71..761644d8f 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -10,7 +10,7 @@ class EuroshareEu(Account): __name__ = "EuroshareEu" __type__ = "account" __version__ = "0.04" - __status__ = "stable" + __status__ = "testing" __description__ = """Euroshare.eu account plugin""" __license__ = "GPLv3" -- cgit v1.2.3 From 8f17f875f6e28f73ddb10da59c6464bd04922222 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 25 Jul 2015 04:59:27 +0200 Subject: Account rewritten --- module/plugins/accounts/EuroshareEu.py | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index 761644d8f..e61b8e853 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -17,7 +17,7 @@ class EuroshareEu(Account): __authors__ = [("zoidberg", "zoidberg@mujmail.cz")] - def load_account_info(self, user, req): + def parse_info(self, user, password, data, req): self.relogin(user) html = self.load("http://euroshare.eu/customer-zone/settings/") @@ -32,11 +32,11 @@ class EuroshareEu(Account): return {'validuntil': validuntil, 'trafficleft': -1, 'premium': premium} - def login(self, user, data, req): + def login(self, user, password, data, req): html = self.load('http://euroshare.eu/customer-zone/login/', post={'trvale' : "1", 'login' : user, - 'password': data['password']}) + 'password': password}) if u">Nesprávne prihlasovacie meno alebo heslo" in html: - self.wrong_password() + self.fail() -- cgit v1.2.3 From a95c217627a1cb651b24e69f20640df40797aff9 Mon Sep 17 00:00:00 2001 From: Walter Purcaro Date: Sat, 25 Jul 2015 09:34:18 +0200 Subject: Account rewritten (2) --- module/plugins/accounts/EuroshareEu.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'module/plugins/accounts/EuroshareEu.py') diff --git a/module/plugins/accounts/EuroshareEu.py b/module/plugins/accounts/EuroshareEu.py index e61b8e853..bc8618250 100644 --- a/module/plugins/accounts/EuroshareEu.py +++ b/module/plugins/accounts/EuroshareEu.py @@ -39,4 +39,4 @@ class EuroshareEu(Account): 'password': password}) if u">Nesprávne prihlasovacie meno alebo heslo" in html: - self.fail() + self.login_fail() -- cgit v1.2.3