potatoeggy / mandown

Comic/manga/webtoon downloader and CBZ/EPUB/MOBI/PDF converter
GNU Affero General Public License v3.0
51 stars 7 forks source link

[BUG] Unable to Download from Manga Dex #65

Closed derzz closed 1 year ago

derzz commented 1 year ago

What broke?

Describe the bug When trying to download from MangaDex, I encountered a Runtime Error that I am unable to continue downloading the files. Surprisingly, Mandown claims there are 34 chapters, however, there are clearly 82 chapters to Spy x Family by the time of this writing. Can you take a look into this?

Steps to reproduce If the downloader broke, please include a URL that breaks it.

Additional context Here is the error that I am experiencing:

Found comic "SPY×FAMILY" from source MangaDex
Downloading 34 chapter(s)...
Chapter 58.5  [#######-----------------------------]   20%  00:01:02
Traceback (most recent call last):

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 196, in _run_module_as_main
    return _run_code(code, main_globals, None,

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\runpy.py", line 86, in _run_code
    exec(code, run_globals)

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\Scripts\mandown.exe\__main__.py", line 7, in <module>
    sys.exit(main())

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\cli.py", line 526, in main
    app()

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\cli.py", line 406, in get
    for title in progress:

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\api.py", line 266, in download_progress
    image_urls = comic.get_chapter_image_urls(chap)

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\comic.py", line 47, in get_chapter_image_urls
    return self.source.fetch_chapter_image_list(chapter)

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\sources\source_mangadex.py", line 108, in fetch_chapter_image_list
    r = self._get(f"https://api.mangadex.org/at-home/server/{chapter_id}").json()

  File "C:\Users\micha\AppData\Local\Programs\Python\Python310\lib\site-packages\mandown\sources\source_mangadex.py", line 135, in _get
    raise RuntimeError(

RuntimeError: This chapter is not downloadable from MangaDex. If you believe this to be an error, please open a GitHub issue.

Let me know if you need more information, thanks!

potatoeggy commented 1 year ago

Hi,

Thank you for opening an issue! However, Mandown only supports English-translated, hosted comics on MangaDex right now. A quick peek at SPY×FAMILY tells me that a bunch of chapters are not available in English:

image

And for those that are available in English, many aren't available through MangaDex, but are instead hosted on external sites. Mandown isn't able to go through those external sites unless they're added as a separate source. If you click them, you should see that a bunch of them require logins, too.

image

(observe the link symbol)