Quote:
Originally Posted by JimmXinu
New Test Version Posted
2023-03-20
- Changes to wattpad API mapping chapter URLs to story URLs.
Wattpad is a complicated site that uses json API URLs and doesn't include the story ID in the chapter URLs. The first URL above is to a specific chapter, while the second is the story URL.
The API call the adapter uses to map a given chapter URL to the story ID/URL wasn't working anymore, looks like the API has changed.
The wattpad adapter is unusual(unique?) in that it does a network hit to map chapter URLs to the story URL much earlier in the process. To the point, I don't generally allow networks reqs there.
But I didn't write that adapter, and it is existing behavior, so I will (try to) fix it.
|
Thank you for the quick fix. I have tested the new version and it works great on the story I linked, but it seems like the fix only work on that story. When I tried another story (ex:
https://www.wattpad.com/709157871-_nosleep_forum), it would redirect back to "the-vision" ?
Log:
Starting QuickView
FFF: DEBUG: 2023-03-20 13:46:19,981: configurable.py(1050): use_browser_cache:
FFF: DEBUG: 2023-03-20 13:46:19,981: configurable.py(1070): use_basic_cache:
FFF: DEBUG: 2023-03-20 13:46:19,982: fetcher_requests.py(114):
---------- REQ (GET) RequestsFetcher
https://www.wattpad.com/v4/parts/843...29&_=709157871
FFF: DEBUG: 2023-03-20 13:46:20,076: fetcher_requests.py(127): response code:200
FFF: DEBUG: 2023-03-20 13:46:20,076: decorators.py(112): fromcache:False
FFF: DEBUG: 2023-03-20 13:46:20,076: requestable.py(55): Encoding:utf8
FFF: DEBUG: 2023-03-20 13:46:20,077: fetcher_requests.py(114):
---------- REQ (GET) RequestsFetcher
https://www.wattpad.com/apiv2/getcategories
FFF: DEBUG: 2023-03-20 13:46:20,112: fetcher_requests.py(127): response code:200
FFF: DEBUG: 2023-03-20 13:46:20,112: decorators.py(112): fromcache:False
FFF: DEBUG: 2023-03-20 13:46:20,112: requestable.py(55): Encoding:utf8
FFF: DEBUG: 2023-03-20 13:46:23,255: calibre_plugins.fanficfare_plugin.dialogs(493): self.extraoptions['anthology_url']:NOT FOUND
FFF: DEBUG: 2023-03-20 13:46:23,258: fetcher_requests.py(114):
---------- REQ (GET) RequestsFetcher
https://www.wattpad.com/v4/parts/843...29&_=709157871
FFF: DEBUG: 2023-03-20 13:46:23,303: fetcher_requests.py(127): response code:200
FFF: DEBUG: 2023-03-20 13:46:23,303: decorators.py(112): fromcache:False
FFF: DEBUG: 2023-03-20 13:46:23,303: requestable.py(55): Encoding:utf8
FFF: DEBUG: 2023-03-20 13:46:23,304: calibre_plugins.fanficfare_plugin.fff_plugin(1125) : FanFicFare v4.21.5
FFF: DEBUG: 2023-03-20 13:46:23,418: configurable.py(1050): use_browser_cache:
FFF: DEBUG: 2023-03-20 13:46:23,418: configurable.py(1070): use_basic_cache:true
FFF: DEBUG: 2023-03-20 13:46:23,419: cache_basic.py(116):
========== MISS (GET) BasicCache
https://www.wattpad.com/api/v3/stories/181493861
FFF: DEBUG: 2023-03-20 13:46:23,419: fetcher_requests.py(114):
---------- REQ (GET) RequestsFetcher
https://www.wattpad.com/api/v3/stories/181493861
FFF: DEBUG: 2023-03-20 13:46:23,495: fetcher_requests.py(127): response code:200
FFF: DEBUG: 2023-03-20 13:46:23,495: decorators.py(112): fromcache:False
FFF: DEBUG: 2023-03-20 13:46:23,495: decorators.py(123): random sleep(1.00-3.00):1.91
FFF: DEBUG: 2023-03-20 13:46:25,411: requestable.py(55): Encoding:utf8
FFF: DEBUG: 2023-03-20 13:46:25,421: base_adapter.py(584): setCoverImage(
https://www.wattpad.com/story/181493...512-k78133.jpg)
FFF: DEBUG: 2023-03-20 13:46:25,421: story.py(1470): addImgUrl(parenturl=https://www.wattpad.com/story/181493861-the-vision,url=https://img.wattpad.com/cover/181493861-512-k78133.jpg,cover=True,coverexclusion=
FFF: DEBUG: 2023-03-20 13:46:25,421: cache_basic.py(116):
========== MISS (GET) BasicCache
https://img.wattpad.com/cover/181493861-512-k78133.jpg
FFF: DEBUG: 2023-03-20 13:46:25,422: fetcher_requests.py(114):
---------- REQ (GET) RequestsFetcher
https://img.wattpad.com/cover/181493861-512-k78133.jpg
FFF: DEBUG: 2023-03-20 13:46:25,492: fetcher_requests.py(127): response code:200
FFF: DEBUG: 2023-03-20 13:46:25,492: decorators.py(112): fromcache:False
FFF: DEBUG: 2023-03-20 13:46:25,492: decorators.py(123): random sleep(1.00-3.00):1.84
FFF: DEBUG: 2023-03-20 13:46:27,396: calibre_plugins.fanficfare_plugin.fff_plugin(1442) : from URL(
https://www.wattpad.com/story/181493861)
FFF: DEBUG: 2023-03-20 13:46:27,404: calibre_plugins.fanficfare_plugin.fff_plugin(1455) : existing found by identifier URL