diff options
author | Philipp Hagemeister <phihag@phihag.de> | 2014-01-27 07:31:54 +0100 |
---|---|---|
committer | Philipp Hagemeister <phihag@phihag.de> | 2014-01-27 07:31:54 +0100 |
commit | 7e8caf30c0552c64cd38eb3471cd6d49e5c1b20e (patch) | |
tree | ae4ed71b5745d8cba34721314c7a28297539c230 /youtube_dl/extractor | |
parent | ca3e054750cacf479b05bd0af1ac0fa4eff2d124 (diff) |
Throw an error if no video formats are found
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/common.py | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index db1ca9edb..f7478d459 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -466,6 +466,9 @@ class InfoExtractor(object): return RATING_TABLE.get(rating.lower(), None) def _sort_formats(self, formats): + if not formats: + raise ExtractorError(u'No video formats found') + def _formats_key(f): # TODO remove the following workaround from ..utils import determine_ext |