From 2d5ed3c27fb32c4ec66d14bc4f1fa168b4da4678 Mon Sep 17 00:00:00 2001 From: devnomnom Date: Sun, 15 Nov 2015 01:07:16 -0500 Subject: [PATCH] [tnaflix] Added handling of embedded videos --- youtube_dl/extractor/generic.py | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) diff --git a/youtube_dl/extractor/generic.py b/youtube_dl/extractor/generic.py index 51516a38a..9b1c83197 100644 --- a/youtube_dl/extractor/generic.py +++ b/youtube_dl/extractor/generic.py @@ -55,7 +55,6 @@ from .snagfilms import SnagFilmsEmbedIE from .screenwavemedia import ScreenwaveMediaIE from .mtv import MTVServicesEmbeddedIE - class GenericIE(InfoExtractor): IE_DESC = 'Generic downloader that works on some sites' _VALID_URL = r'.*' @@ -1045,6 +1044,19 @@ class GenericIE(InfoExtractor): 'description': 'Tabletop: Dread, Last Thoughts', 'duration': 51690, }, + }, + # tnaflix embed + { + 'url': 'http://fantasti.cc/watch/9358999/Glam-euro-lesbians-get-off/', + 'info_dict': { + 'id': '635797', + 'ext': 'mp4', + 'title': 'Glam euro lesbians get off', + 'description': 'Glam euro lesbians get off with fetish hitachi magic wands action', + 'duration': 324, + 'age_limit': 18, + 'uploader': 'mariac895', + } } ] @@ -1778,6 +1790,13 @@ class GenericIE(InfoExtractor): self._proto_relative_url(unescapeHTML(mobj.group(1))), 'AdobeTVVideo') + # Look for embedded tnaflix player + tnaflix_urls = [url for url in re.findall( + r'(?Phttps?://(?:www\.)?tnaflix\.com/[^/]+/[^/]+/video\d+)', + webpage)] + if tnaflix_urls: + return _playlist_from_matches(tnaflix_urls, ie='TNAFlix') + def check_video(vurl): if YoutubeIE.suitable(vurl): return True