From ca673139009a67ca0848b2eb83790cacd1626884 Mon Sep 17 00:00:00 2001 From: remitamine Date: Tue, 21 Jul 2015 08:51:56 +0100 Subject: [PATCH] [cbs] fix downloading and change rtmp test to f4m --- youtube_dl/extractor/cbs.py | 19 ++----------------- 1 file changed, 2 insertions(+), 17 deletions(-) diff --git a/youtube_dl/extractor/cbs.py b/youtube_dl/extractor/cbs.py index 75fffb156..96147a8da 100644 --- a/youtube_dl/extractor/cbs.py +++ b/youtube_dl/extractor/cbs.py @@ -1,7 +1,7 @@ from __future__ import unicode_literals from .common import InfoExtractor - +from ..utils import smuggle_url class CBSIE(InfoExtractor): _VALID_URL = r'https?://(?:www\.)?(?:cbs\.com/shows/[^/]+/(?:video|artist)|colbertlateshow\.com/(?:video|podcasts))/[^/]+/(?P[^/]+)' @@ -10,31 +10,21 @@ class CBSIE(InfoExtractor): 'url': 'http://www.cbs.com/shows/garth-brooks/video/_u7W953k6la293J7EPTd9oHkSPs6Xn6_/connect-chat-feat-garth-brooks/', 'info_dict': { 'id': '4JUVEwq3wUT7', - 'display_id': 'connect-chat-feat-garth-brooks', 'ext': 'flv', 'title': 'Connect Chat feat. Garth Brooks', 'description': 'Connect with country music singer Garth Brooks, as he chats with fans on Wednesday November 27, 2013. Be sure to tune in to Garth Brooks: Live from Las Vegas, Friday November 29, at 9/8c on CBS!', 'duration': 1495, }, - 'params': { - # rtmp download - 'skip_download': True, - }, '_skip': 'Blocked outside the US', }, { 'url': 'http://www.cbs.com/shows/liveonletterman/artist/221752/st-vincent/', 'info_dict': { 'id': 'WWF_5KqY3PK1', - 'display_id': 'st-vincent', 'ext': 'flv', 'title': 'Live on Letterman - St. Vincent', 'description': 'Live On Letterman: St. Vincent in concert from New York\'s Ed Sullivan Theater on Tuesday, July 16, 2014.', 'duration': 3221, }, - 'params': { - # rtmp download - 'skip_download': True, - }, '_skip': 'Blocked outside the US', }, { 'url': 'http://colbertlateshow.com/video/8GmB0oY0McANFvp2aEffk9jZZZ2YyXxy/the-colbeard/', @@ -50,9 +40,4 @@ class CBSIE(InfoExtractor): real_id = self._search_regex( [r"video\.settings\.pid\s*=\s*'([^']+)';", r"cbsplayer\.pid\s*=\s*'([^']+)';"], webpage, 'real video ID') - return { - '_type': 'url_transparent', - 'ie_key': 'ThePlatform', - 'url': 'theplatform:%s' % real_id, - 'display_id': display_id, - } + return self.url_result(smuggle_url('http://link.theplatform.com/s/dJ5BDC/%s/meta.smil?format=smil&mbr=true&manifest=f4m' % real_id, {'force_smil_url': True}))