summaryrefslogtreecommitdiffstats
path: root/module/plugins/crypter
diff options
context:
space:
mode:
authorGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-19 00:05:58 +0200
committerGravatar Walter Purcaro <vuolter@users.noreply.github.com> 2015-07-19 00:05:58 +0200
commitdad722ac7255640e7e0541c4094a4d2e4de79cd3 (patch)
tree893a08e83fb9b465cd0ecf0b0315a5e820b06b06 /module/plugins/crypter
parent[Hoster] Fix the http request issue (diff)
downloadpyload-dad722ac7255640e7e0541c4094a4d2e4de79cd3.tar.xz
Code cosmetics (2)
Diffstat (limited to 'module/plugins/crypter')
-rw-r--r--module/plugins/crypter/DailymotionComFolder.py2
-rw-r--r--module/plugins/crypter/FilecryptCc.py4
-rw-r--r--module/plugins/crypter/LinkCryptWs.py8
-rw-r--r--module/plugins/crypter/MediafireComFolder.py6
-rw-r--r--module/plugins/crypter/NCryptIn.py2
-rw-r--r--module/plugins/crypter/RelinkUs.py2
-rw-r--r--module/plugins/crypter/ShSt.py4
-rw-r--r--module/plugins/crypter/YoutubeComFolder.py2
8 files changed, 15 insertions, 15 deletions
diff --git a/module/plugins/crypter/DailymotionComFolder.py b/module/plugins/crypter/DailymotionComFolder.py
index 84d2c773c..d3d68b7c7 100644
--- a/module/plugins/crypter/DailymotionComFolder.py
+++ b/module/plugins/crypter/DailymotionComFolder.py
@@ -102,4 +102,4 @@ class DailymotionComFolder(Crypter):
p_videos = self.get_videos(p_id)
p_folder = fs_join(self.core.config.get("general", "download_folder"), p_owner, p_name)
self.log_debug("%s video\s found on playlist \"%s\"" % (len(p_videos), p_name))
- self.packages.append((p_name, p_videos, p_folder)) #: folder is NOT recognized by pyload 0.4.9!
+ self.packages.append((p_name, p_videos, p_folder)) #: Folder is NOT recognized by pyload 0.4.9!
diff --git a/module/plugins/crypter/FilecryptCc.py b/module/plugins/crypter/FilecryptCc.py
index 341b1e13f..624dadb94 100644
--- a/module/plugins/crypter/FilecryptCc.py
+++ b/module/plugins/crypter/FilecryptCc.py
@@ -88,7 +88,7 @@ class FilecryptCc(Crypter):
m = re.search(self.CAPTCHA_PATTERN, self.html)
m2 = re.search(self.CIRCLE_CAPTCHA_PATTERN, self.html)
- if m: #: normal captcha
+ if m: #: Normal captcha
self.log_debug("Captcha-URL: %s" % m.group(1))
captcha_code = self.decrypt_captcha(urlparse.urljoin(self.base_url, m.group(1)),
@@ -97,7 +97,7 @@ class FilecryptCc(Crypter):
self.site_with_links = self.load(self.pyfile.url,
post={'recaptcha_response_field': captcha_code})
- elif m2: #: circle captcha
+ elif m2: #: Circle captcha
self.log_debug("Captcha-URL: %s" % m2.group(1))
captcha_code = self.decrypt_captcha('%s%s?c=abc' %(self.base_url, m2.group(1)),
diff --git a/module/plugins/crypter/LinkCryptWs.py b/module/plugins/crypter/LinkCryptWs.py
index a5d4d7e59..4fe2384da 100644
--- a/module/plugins/crypter/LinkCryptWs.py
+++ b/module/plugins/crypter/LinkCryptWs.py
@@ -42,7 +42,7 @@ class LinkCryptWs(Crypter):
self.req.cj.setCookie("linkcrypt.ws", "language", "en")
#: Request package
- self.req.http.c.setopt(pycurl.USERAGENT, "Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko") #: better chance to not get those key-captchas
+ self.req.http.c.setopt(pycurl.USERAGENT, "Mozilla/5.0 (Windows NT 6.3; WOW64; Trident/7.0; rv:11.0) like Gecko") #: Better chance to not get those key-captchas
self.html = self.load(self.pyfile.url)
@@ -68,13 +68,13 @@ class LinkCryptWs(Crypter):
self.unlock_password_protection()
self.handle_errors()
- #: get unrar password
+ #: Get unrar password
self.getunrarpw()
#: Get package name and folder
package_name, folder_name = self.get_package_info()
- # get the container definitions from script section
+ #: Get the container definitions from script section
self.get_container_html()
#: Extract package links
@@ -234,7 +234,7 @@ class LinkCryptWs(Crypter):
self.log_debug('Search for %s Container links' % type.upper())
- if not type.isalnum(): #: check to prevent broken re-pattern (cnl2, rsdf, ccf, dlc, web are all alpha-numeric)
+ if not type.isalnum(): #: Check to prevent broken re-pattern (cnl2, rsdf, ccf, dlc, web are all alpha-numeric)
self.fail(_("Unknown container type: %s") % type) #@TODO: Replace with self.error in 0.4.10
for line in self.container_html:
diff --git a/module/plugins/crypter/MediafireComFolder.py b/module/plugins/crypter/MediafireComFolder.py
index 9ec8f9efe..02b5369ec 100644
--- a/module/plugins/crypter/MediafireComFolder.py
+++ b/module/plugins/crypter/MediafireComFolder.py
@@ -29,14 +29,14 @@ class MediafireComFolder(Crypter):
self.log_debug("Location (%d): %s" % (result, url))
if result == 0:
- #: load and parse html
+ #: Load and parse html
html = self.load(pyfile.url)
m = re.search(self.LINK_PATTERN, html)
if m:
- #: file page
+ #: File page
self.urls.append("http://www.mediafire.com/file/%s" % m.group(1))
else:
- #: folder page
+ #: Folder page
m = re.search(self.FOLDER_KEY_PATTERN, html)
if m:
folder_key = m.group(1)
diff --git a/module/plugins/crypter/NCryptIn.py b/module/plugins/crypter/NCryptIn.py
index 8abf06602..195bde539 100644
--- a/module/plugins/crypter/NCryptIn.py
+++ b/module/plugins/crypter/NCryptIn.py
@@ -69,7 +69,7 @@ class NCryptIn(Crypter):
#: Extract package links
for link_source_type in self.links_source_order:
package_links.extend(self.handle_link_source(link_source_type))
- if package_links: #: use only first source which provides links
+ if package_links: #: Use only first source which provides links
break
package_links = set(package_links)
diff --git a/module/plugins/crypter/RelinkUs.py b/module/plugins/crypter/RelinkUs.py
index b270ccbbd..77d5eff50 100644
--- a/module/plugins/crypter/RelinkUs.py
+++ b/module/plugins/crypter/RelinkUs.py
@@ -89,7 +89,7 @@ class RelinkUs(Crypter):
package_links = []
for sources in self.PREFERRED_LINK_SOURCES:
package_links.extend(self.handle_link_source(sources))
- if package_links: #: use only first source which provides links
+ if package_links: #: Use only first source which provides links
break
package_links = set(package_links)
diff --git a/module/plugins/crypter/ShSt.py b/module/plugins/crypter/ShSt.py
index a65522aea..05a5518d3 100644
--- a/module/plugins/crypter/ShSt.py
+++ b/module/plugins/crypter/ShSt.py
@@ -22,9 +22,9 @@ class ShSt(Crypter):
def decrypt(self, pyfile):
- # if we use curl as a user agent, we will get a straight redirect (no waiting!)
+ #: If we use curl as a user agent, we will get a straight redirect (no waiting!)
self.req.http.c.setopt(pycurl.USERAGENT, "curl/7.42.1")
- # fetch the target URL
+ #: Fetch the target URL
header = self.load(self.pyfile.url, just_header = True, decode = False)
target_url = header["location"]
self.urls.append(target_url)
diff --git a/module/plugins/crypter/YoutubeComFolder.py b/module/plugins/crypter/YoutubeComFolder.py
index 4b11e1244..b68630f44 100644
--- a/module/plugins/crypter/YoutubeComFolder.py
+++ b/module/plugins/crypter/YoutubeComFolder.py
@@ -142,6 +142,6 @@ class YoutubeComFolder(Crypter):
else:
p_urls = map(urlize, p_videos)
- self.packages.append((p_name, p_urls, p_folder)) #: folder is NOT recognized by pyload 0.4.9!
+ self.packages.append((p_name, p_urls, p_folder)) #: Folder is NOT recognized by pyload 0.4.9!
addedvideos.extend(p_videos)