From 8c03b5dc57300911f14b6547dd6165cbedf14afc Mon Sep 17 00:00:00 2001 From: jaykay12 Date: Wed, 4 Oct 2017 14:08:37 +0530 Subject: [PATCH 1/3] Modified Regex --- youtube_dl/extractor/pornflip.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/youtube_dl/extractor/pornflip.py b/youtube_dl/extractor/pornflip.py index a4a5d390e..7de7fdf87 100644 --- a/youtube_dl/extractor/pornflip.py +++ b/youtube_dl/extractor/pornflip.py @@ -14,7 +14,7 @@ from ..utils import ( class PornFlipIE(InfoExtractor): - _VALID_URL = r'https?://(?:www\.)?pornflip\.com/(?:v|embed)/(?P[0-9A-Za-z]{11})' + _VALID_URL = r'https?://(?:www\.)?pornflip\.com/(?:v|embed)/(?P[0-9A-Za-z-]{11})' _TESTS = [{ 'url': 'https://www.pornflip.com/v/wz7DfNhMmep', 'md5': '98c46639849145ae1fd77af532a9278c', From 2918f4aaa7199f74a24c55595cdc4f86a795bf94 Mon Sep 17 00:00:00 2001 From: jaykay12 Date: Wed, 4 Oct 2017 14:15:31 +0530 Subject: [PATCH 2/3] Added test --- youtube_dl/extractor/pornflip.py | 20 ++++++++++++++++++++ 1 file changed, 20 insertions(+) diff --git a/youtube_dl/extractor/pornflip.py b/youtube_dl/extractor/pornflip.py index 7de7fdf87..95044e70e 100644 --- a/youtube_dl/extractor/pornflip.py +++ b/youtube_dl/extractor/pornflip.py @@ -34,6 +34,26 @@ class PornFlipIE(InfoExtractor): }, { 'url': 'https://www.pornflip.com/embed/wz7DfNhMmep', 'only_matching': True, + }, { + 'url': 'https://www.pornflip.com/v/EkRD6-vS2-s', + 'md5': 'd1daf08112bce8c02d18da2a7c928b22', + 'info_dict': { + 'id': 'EkRD6-vS2-s', + 'ext': 'mp4', + 'title': 'Deepthroat creampie for norwegian step mom', + 'thumbnail': r're:^https?://.*\.jpg$', + 'duration': 334, + 'timestamp': 1506447970, + 'upload_date': '20170926', + 'uploader_id': '160131', + 'uploader': 'Abarrambbar', + 'view_count': int, + 'age_limit': 18, + } + + }, { + 'url': 'https://www.pornflip.com/embed/EkRD6-vS2-s', + 'only_matching': True, }] def _real_extract(self, url): From 2432f301e84d86be435ca6f466b7f74323d45165 Mon Sep 17 00:00:00 2001 From: jaykay12 Date: Wed, 4 Oct 2017 23:18:52 +0530 Subject: [PATCH 3/3] Fixed Issues --- youtube_dl/extractor/pornflip.py | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/youtube_dl/extractor/pornflip.py b/youtube_dl/extractor/pornflip.py index 95044e70e..ee04936e1 100644 --- a/youtube_dl/extractor/pornflip.py +++ b/youtube_dl/extractor/pornflip.py @@ -35,25 +35,11 @@ class PornFlipIE(InfoExtractor): 'url': 'https://www.pornflip.com/embed/wz7DfNhMmep', 'only_matching': True, }, { - 'url': 'https://www.pornflip.com/v/EkRD6-vS2-s', - 'md5': 'd1daf08112bce8c02d18da2a7c928b22', - 'info_dict': { - 'id': 'EkRD6-vS2-s', - 'ext': 'mp4', - 'title': 'Deepthroat creampie for norwegian step mom', - 'thumbnail': r're:^https?://.*\.jpg$', - 'duration': 334, - 'timestamp': 1506447970, - 'upload_date': '20170926', - 'uploader_id': '160131', - 'uploader': 'Abarrambbar', - 'view_count': int, - 'age_limit': 18, - } - + 'url': 'https://www.pornflip.com/v/EkRD6-vS2-s', + 'only_matching': True, }, { - 'url': 'https://www.pornflip.com/embed/EkRD6-vS2-s', - 'only_matching': True, + 'url': 'https://www.pornflip.com/embed/EkRD6-vS2-s', + 'only_matching': True, }] def _real_extract(self, url):