mikf / gallery-dl

Command-line program to download image galleries and collections from several image hosting sites
GNU General Public License v2.0
11.48k stars 939 forks source link

[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group' #20

Closed jtara1 closed 7 years ago

jtara1 commented 7 years ago

Is the kissmanga downloader working? Did I miss something?

PS C:\Users\James\Downloads> gallery-dl http://kissmanga.com/Manga/Monster
[kissmanga][info] Solving Cloudflare challenge
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'group'

KeyboardInterrupt
PS C:\Users\James\Downloads>

Also, if it is the cloudfare bypasser that's failing, why not use cfscrape module? It was easy for me to use and integrate into one of my projects.

mikf commented 7 years ago

The kissmanga extractor is supposed to be working and it works just fine for some manga series (http://kissmanga.com/Manga/Urban-Tales). What is failing here is the regular expression used to get volume, chapter and title information.

mikf commented 7 years ago

Fixed extraction for your example and all the bigger manga series, which had a different volume/chapter formatting than regular ones. Please let me know if you find any other examples that don't work.

LoganJM commented 5 years ago

Hi @mikf I am coming accross this same error, specifically with Houseki no Kuni from Kissmanga. (https://kissmanga.com/Manga/Houseki-no-Kuni) Here is the output to my console with the verbose option enabled:

C:\Users\Logan>gallery-dl https://kissmanga.com/Manga/Houseki-no-Kuni --verbose
[gallery-dl][debug] Version 1.6.2-dev
[gallery-dl][debug] Python 3.6.3 - Windows-10-10.0.17134-SP0
[gallery-dl][debug] requests 2.20.0 - urllib3 1.24.1
[gallery-dl][debug] Starting DownloadJob for 'https://kissmanga.com/Manga/Houseki-no-Kuni'
[kissmanga][debug] Using KissmangaMangaExtractor for 'https://kissmanga.com/Manga/Houseki-no-Kuni'
[urllib3.connectionpool][debug] Starting new HTTP connection (1): kissmanga.com:80
[urllib3.connectionpool][debug] http://kissmanga.com:80 "GET /Manga/Houseki-no-Kuni HTTP/1.1" 301 None
[urllib3.connectionpool][debug] Starting new HTTPS connection (1): kissmanga.com:443
[urllib3.connectionpool][debug] https://kissmanga.com:443 "GET /Manga/Houseki-no-Kuni HTTP/1.1" 200 None
[kissmanga][error] An unexpected error occurred: AttributeError - 'NoneType' object has no attribute 'groups'. Please run gallery-dl again with the --verbose flag, copy its output and report this issue on https://github.com/mikf/gallery-dl/issues .
[kissmanga][debug]
Traceback (most recent call last):
  File "c:\users\logan\appdata\local\programs\python\python36\lib\site-packages\gallery_dl\job.py", line 51, in run
    for msg in self.extractor:
  File "c:\users\logan\appdata\local\programs\python\python36\lib\site-packages\gallery_dl\extractor\common.py", line 254, in items
    chapters = self.chapters(page)
  File "c:\users\logan\appdata\local\programs\python\python36\lib\site-packages\gallery_dl\extractor\kissmanga.py", line 95, in chapters
    self.parse_chapter_string(data)
  File "c:\users\logan\appdata\local\programs\python\python36\lib\site-packages\gallery_dl\extractor\kissmanga.py", line 58, in parse_chapter_string
    volume, chapter, minor, title = match.groups()
AttributeError: 'NoneType' object has no attribute 'groups'

I am experiencing the same error on the current non-dev version as well