mirror of
https://github.com/mikf/gallery-dl.git
synced 2025-01-31 11:41:35 +01:00
Revert "[kissmanga] workaround for CAPTCHAs (#818)"
This reverts commit 4cf3d54718812ae2bcf6cd5ee39347409946921e.
This commit is contained in:
parent
0cac14c3bd
commit
699062b91f
@ -9,10 +9,9 @@
|
||||
"""Extract manga-chapters and entire manga from https://kissmanga.com/"""
|
||||
|
||||
from .common import ChapterExtractor, MangaExtractor, Extractor
|
||||
from .. import text, aes
|
||||
from .. import text, aes, exception
|
||||
from ..cache import cache
|
||||
import hashlib
|
||||
import time
|
||||
import ast
|
||||
import re
|
||||
|
||||
@ -25,7 +24,18 @@ class RedirectMixin():
|
||||
response = Extractor.request(self, url, **kwargs)
|
||||
if not response.history or "/AreYouHuman" not in response.url:
|
||||
return response
|
||||
time.sleep(2)
|
||||
if self.config("captcha", "stop") == "wait":
|
||||
self.log.warning(
|
||||
"Redirect to \n%s\nVisit this URL in your browser, solve "
|
||||
"the CAPTCHA, and press ENTER to continue", response.url)
|
||||
try:
|
||||
input()
|
||||
except (EOFError, OSError):
|
||||
pass
|
||||
else:
|
||||
raise exception.StopExtraction(
|
||||
"Redirect to \n%s\nVisit this URL in your browser and "
|
||||
"solve the CAPTCHA to continue", response.url)
|
||||
|
||||
|
||||
class KissmangaBase(RedirectMixin):
|
||||
|
Loading…
x
Reference in New Issue
Block a user