1
0
mirror of https://github.com/mikf/gallery-dl.git synced 2024-11-22 10:42:34 +01:00

[khinsider] fix filename extension and test-pattern

This commit is contained in:
Mike Fährmann 2017-11-28 19:35:47 +01:00
parent c0bcf8e343
commit 55c64cad4b
No known key found for this signature in database
GPG Key ID: 5680CA389D365A88
4 changed files with 10 additions and 9 deletions

View File

@ -1,5 +1,7 @@
# Changelog
## Unreleased
## 1.0.2 - 2017-11-24
- Added an option to set a [custom user-agent string](https://github.com/mikf/gallery-dl/blob/master/docs/configuration.rst#extractoruser-agent)
- Improved retry behavior for failed HTTP requests

View File

@ -21,8 +21,8 @@ class KhinsiderSoundtrackExtractor(AsynchronousExtractor):
r"game-soundtracks/album/([^/?&#]+)"]
test = [(("http://downloads.khinsider.com/game-soundtracks/"
"album/horizon-riders-wii-"), {
"pattern": ("https?://\d+\.\d+\.\d+\.\d+/ost/horizon-riders-wii-/"
"[^/]+/horizon-riders-wii-full-soundtrack\.mp3"),
"pattern": (r"https?://\d+\.\d+\.\d+\.\d+/ost/horizon-riders-wii/[^/]+"
r"/Horizon%20Riders%20Wii%20-%20Full%20Soundtrack\.mp3"),
"count": 1,
"keyword": "d91cf3edee6713b536eaf3995743f0be7dc72f68",
})]
@ -63,7 +63,6 @@ class KhinsiderSoundtrackExtractor(AsynchronousExtractor):
for num, url in enumerate(text.extract_iter(
page, '<td><a href="', '"'), 1):
page = self.request(url, encoding="utf-8").text
name, pos = text.extract(page, "Song name: <b>", "</b>")
url , pos = text.extract(
page, '<p><a style="color: #21363f;" href="', '"', pos)
yield url, text.nameext_from_url(name, {"num": num})
url = text.extract(
page, '<p><a style="color: #21363f;" href="', '"')[0]
yield url, text.nameext_from_url(url, {"num": num})

View File

@ -19,9 +19,9 @@ class RebeccablacktechThreadExtractor(chan.FoolfuukaThreadExtractor):
r"|rbt\.asia)/([^/]+)/thread/(\d+)"]
test = [
("https://rbt.asia/g/thread/61487650/", {
"url": "484f20ea9b9b58f6abb0cd37eaeab22431ac22c2",
"url": "fadd274b25150a1bdf03a40c58db320fa3b617c4",
}),
("https://archive.rebeccablacktech.com/g/thread/61487650/", {
"url": "484f20ea9b9b58f6abb0cd37eaeab22431ac22c2",
"url": "fadd274b25150a1bdf03a40c58db320fa3b617c4",
}),
]

View File

@ -6,4 +6,4 @@
# it under the terms of the GNU General Public License version 2 as
# published by the Free Software Foundation.
__version__ = "1.0.2"
__version__ = "1.0.3-dev"