From 7df97fb59f7994c32ecf552ee9dfec6c6be3bb1e Mon Sep 17 00:00:00 2001 From: Filippo Valsorda Date: Fri, 22 Jun 2012 13:57:17 +0200 Subject: display a meaningful error message on rental videos (#359) --- youtube_dl/InfoExtractors.py | 5 +++++ 1 file changed, 5 insertions(+) (limited to 'youtube_dl') diff --git a/youtube_dl/InfoExtractors.py b/youtube_dl/InfoExtractors.py index 40f96ad76..d02bd29f7 100644 --- a/youtube_dl/InfoExtractors.py +++ b/youtube_dl/InfoExtractors.py @@ -311,6 +311,11 @@ class YoutubeIE(InfoExtractor): self._downloader.trouble(u'ERROR: "token" parameter not in video info for unknown reason') return + # Check for "rental" videos + if 'ypc_video_rental_bar_text' in video_info and 'author' not in video_info: + self._downloader.trouble(u'ERROR: "rental" videos not supported') + return + # Start extracting information self.report_information_extraction(video_id) -- cgit v1.2.3