diff --git a/extractor/osen.py b/extractor/osen.py index 4f13f86..2be4d9b 100644 --- a/extractor/osen.py +++ b/extractor/osen.py @@ -5,7 +5,7 @@ from gallery_dl import exception, text from gallery_dl.extractor.common import Extractor, Message -BASE_PATTERN = r"(?:https?://)?www\.osen\.co\.kr" +BASE_PATTERN = r"(?:https?://)?(?:www\.)?osen\.co\.kr" class OsenExtractor(Extractor): @@ -40,7 +40,7 @@ class OsenArticleExtractor(OsenExtractor): directory_fmt = ("{category}", "{article_id}") archive_fmt = "{article_id}_{filename}_{num}" pattern = BASE_PATTERN + r"/article/(G\d+)" - example = "https://www.osen.co.kr//article/G12345678910" + example = "https://www.osen.co.kr/article/G12345678910" def __init__(self, match): OsenExtractor.__init__(self, match) diff --git a/test/results/osen.py b/test/results/osen.py index 314903c..429a6c0 100644 --- a/test/results/osen.py +++ b/test/results/osen.py @@ -13,4 +13,13 @@ "title": "(여자)아이들 미연 '사랑스럽게'", "date": "dt:2024-04-18 16:32:00", }, + { + "#url": "https://osen.co.kr/article/G1112452170", + "#category": ("", "osen", "article"), + "#class": osen.OsenArticleExtractor, + "#pattern": IMAGE_URL_PATTERN, + "#count": 1, + "title": "에스타 윈터, 미소와 함께 퇴장", + "date": "dt:2024-11-06 11:38:00", + }, )