[hentaihere] transition to https
This commit is contained in:
@@ -1,6 +1,6 @@
|
|||||||
# -*- coding: utf-8 -*-
|
# -*- coding: utf-8 -*-
|
||||||
|
|
||||||
# Copyright 2016 Mike Fährmann
|
# Copyright 2016-2017 Mike Fährmann
|
||||||
#
|
#
|
||||||
# This program is free software; you can redistribute it and/or modify
|
# This program is free software; you can redistribute it and/or modify
|
||||||
# it under the terms of the GNU General Public License version 2 as
|
# it under the terms of the GNU General Public License version 2 as
|
||||||
@@ -18,11 +18,11 @@ class HentaihereMangaExtractor(hentaicdn.HentaicdnMangaExtractor):
|
|||||||
category = "hentaihere"
|
category = "hentaihere"
|
||||||
pattern = [r"(?:https?://)?(?:www\.)?hentaihere\.com/m/S(\d+)/?$"]
|
pattern = [r"(?:https?://)?(?:www\.)?hentaihere\.com/m/S(\d+)/?$"]
|
||||||
test = [
|
test = [
|
||||||
("http://hentaihere.com/m/S13812", {
|
("https://hentaihere.com/m/S13812", {
|
||||||
"url": "167ec26c73c7d01ad8ad0a2b88257a901aa8330e",
|
"url": "d1ba6e28bb2162e844f8559c2b2725ba0a093559",
|
||||||
}),
|
}),
|
||||||
("http://hentaihere.com/m/S7608", {
|
("https://hentaihere.com/m/S7608", {
|
||||||
"url": "17dd982270456ce51ec7189f9e37728ef9f894c8",
|
"url": "6c5239758dc93f6b1b4175922836c10391b174f7",
|
||||||
}),
|
}),
|
||||||
]
|
]
|
||||||
|
|
||||||
@@ -32,7 +32,7 @@ class HentaihereMangaExtractor(hentaicdn.HentaicdnMangaExtractor):
|
|||||||
|
|
||||||
def get_chapters(self):
|
def get_chapters(self):
|
||||||
return text.extract_iter(
|
return text.extract_iter(
|
||||||
self.request("http://hentaihere.com/m/S" + self.gid).text,
|
self.request("https://hentaihere.com/m/S" + self.gid).text,
|
||||||
'<li class="sub-chp clearfix">\n<a href="', '"'
|
'<li class="sub-chp clearfix">\n<a href="', '"'
|
||||||
)
|
)
|
||||||
|
|
||||||
@@ -41,7 +41,7 @@ class HentaihereChapterExtractor(hentaicdn.HentaicdnChapterExtractor):
|
|||||||
"""Extractor for a single manga chapter from hentaihere.com"""
|
"""Extractor for a single manga chapter from hentaihere.com"""
|
||||||
category = "hentaihere"
|
category = "hentaihere"
|
||||||
pattern = [r"(?:https?://)?(?:www\.)?hentaihere\.com/m/S(\d+)/(\d+)"]
|
pattern = [r"(?:https?://)?(?:www\.)?hentaihere\.com/m/S(\d+)/(\d+)"]
|
||||||
test = [("http://hentaihere.com/m/S13812/1/1/", {
|
test = [("https://hentaihere.com/m/S13812/1/1/", {
|
||||||
"url": "fb5fc4d7cc194116960eaa648c7e045a6e6f0c11",
|
"url": "fb5fc4d7cc194116960eaa648c7e045a6e6f0c11",
|
||||||
"keyword": "e8625ccca8466a5dee089394fc29efea6d6e2950",
|
"keyword": "e8625ccca8466a5dee089394fc29efea6d6e2950",
|
||||||
})]
|
})]
|
||||||
@@ -49,7 +49,7 @@ class HentaihereChapterExtractor(hentaicdn.HentaicdnChapterExtractor):
|
|||||||
def __init__(self, match):
|
def __init__(self, match):
|
||||||
hentaicdn.HentaicdnChapterExtractor.__init__(self)
|
hentaicdn.HentaicdnChapterExtractor.__init__(self)
|
||||||
self.gid, self.chapter = match.groups()
|
self.gid, self.chapter = match.groups()
|
||||||
self.url = "http://hentaihere.com/m/S{}/{}/1".format(
|
self.url = "https://hentaihere.com/m/S{}/{}/1".format(
|
||||||
self.gid, self.chapter
|
self.gid, self.chapter
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|||||||
@@ -68,7 +68,6 @@ class KissmangaChapterExtractor(KissmangaExtractor):
|
|||||||
|
|
||||||
def items(self):
|
def items(self):
|
||||||
page = self.request(self.url).text
|
page = self.request(self.url).text
|
||||||
print(page)
|
|
||||||
data = self.get_job_metadata(page)
|
data = self.get_job_metadata(page)
|
||||||
imgs = self.get_image_urls(page)
|
imgs = self.get_image_urls(page)
|
||||||
data["count"] = len(imgs)
|
data["count"] = len(imgs)
|
||||||
|
|||||||
@@ -48,7 +48,7 @@ def _generate_test(extr, tcase):
|
|||||||
|
|
||||||
|
|
||||||
# enable selective testing for direct calls
|
# enable selective testing for direct calls
|
||||||
skip = ["exhentai", "mangafox"]
|
skip = ["exhentai", "kissmanga", "mangafox"]
|
||||||
if __name__ == '__main__' and len(sys.argv) > 1:
|
if __name__ == '__main__' and len(sys.argv) > 1:
|
||||||
extractors = [
|
extractors = [
|
||||||
extr for extr in extractor.extractors()
|
extr for extr in extractor.extractors()
|
||||||
|
|||||||
Reference in New Issue
Block a user