From 67b8ab3ca6b30aba7ae58ae81b707f369d057064 Mon Sep 17 00:00:00 2001 From: jomo Date: Fri, 23 Jan 2015 15:23:19 +0100 Subject: [PATCH 1/2] download raw videos from LiveLeak, without branding --- youtube_dl/extractor/liveleak.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/youtube_dl/extractor/liveleak.py b/youtube_dl/extractor/liveleak.py index b04be1e8c..00a3c686f 100644 --- a/youtube_dl/extractor/liveleak.py +++ b/youtube_dl/extractor/liveleak.py @@ -82,7 +82,8 @@ class LiveLeakIE(InfoExtractor): formats = [{ 'format_note': s.get('label'), - 'url': s['file'], + # removing this from the URL gives us the raw video without LiveLeak branding + 'url': s['file'].replace('.h264_base.mp4', ''), } for s in sources] self._sort_formats(formats) From 58199b3e9f222ccabdbc7cb00bf2772ab69da3ad Mon Sep 17 00:00:00 2001 From: jomo Date: Fri, 23 Jan 2015 15:59:15 +0100 Subject: [PATCH 2/2] fix tests --- youtube_dl/extractor/liveleak.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/youtube_dl/extractor/liveleak.py b/youtube_dl/extractor/liveleak.py index 00a3c686f..f54f8636a 100644 --- a/youtube_dl/extractor/liveleak.py +++ b/youtube_dl/extractor/liveleak.py @@ -11,10 +11,10 @@ class LiveLeakIE(InfoExtractor): _VALID_URL = r'^(?:http://)?(?:\w+\.)?liveleak\.com/view\?(?:.*?)i=(?P[\w_]+)(?:.*)' _TESTS = [{ 'url': 'http://www.liveleak.com/view?i=757_1364311680', - 'md5': '0813c2430bea7a46bf13acf3406992f4', + 'md5': '50f79e05ba149149c1b4ea961223d5b3', 'info_dict': { 'id': '757_1364311680', - 'ext': 'mp4', + 'ext': 'flv', 'description': 'extremely bad day for this guy..!', 'uploader': 'ljfriel2', 'title': 'Most unlucky car accident'