MCPcopy Index your code
hub / github.com/pyload/pyload / check_errors

Method check_errors

module/plugins/hoster/HighWayMe.py:30–51  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

28 self.chunk_limit = 4
29
30 def check_errors(self):
31 if "<code>5</code>" in self.data:
32 self.account.relogin()
33 self.retry()
34
35 elif "<code>9</code>" in self.data:
36 self.offline()
37
38 elif "downloadlimit" in self.data:
39 self.log_warning(_("Reached maximum connctions"))
40 self.retry(5, 60, _("Reached maximum connctions"))
41
42 elif "trafficlimit" in self.data:
43 self.log_warning(_("Reached daily limit"))
44 self.retry(
45 wait=seconds_to_midnight(),
46 msg="Daily limit for this host reached")
47
48 elif "<code>8</code>" in self.data:
49 self.log_warning(
50 _("Hoster temporarily unavailable, waiting 1 minute and retry"))
51 self.retry(5, 60, _("Hoster is temporarily unavailable"))
52
53 def handle_premium(self, pyfile):
54 for _i in range(5):

Callers 1

handle_premiumMethod · 0.95

Calls 6

seconds_to_midnightFunction · 0.85
log_warningMethod · 0.80
_Function · 0.50
reloginMethod · 0.45
retryMethod · 0.45
offlineMethod · 0.45

Tested by

no test coverage detected