diff options
author | Sergey M․ <dstftw@gmail.com> | 2015-11-28 18:50:21 +0600 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2015-11-28 18:50:21 +0600 |
commit | 5faf9fed7e1c7922578467cfd48db5867ef9b91b (patch) | |
tree | 4707ca040e4d4012d794371ffa7ae93d76f24a69 /youtube_dl/extractor/youtube.py | |
parent | 13a9b69b093532fe085e498c4fed2c56ced6cc92 (diff) |
[youtube] Clarify rationale for yt:stretch validation
Diffstat (limited to 'youtube_dl/extractor/youtube.py')
-rw-r--r-- | youtube_dl/extractor/youtube.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/youtube_dl/extractor/youtube.py b/youtube_dl/extractor/youtube.py index 9da8d4bc5..1c2420a33 100644 --- a/youtube_dl/extractor/youtube.py +++ b/youtube_dl/extractor/youtube.py @@ -1514,6 +1514,8 @@ class YoutubeIE(YoutubeBaseInfoExtractor): if stretched_m: w = float(stretched_m.group('w')) h = float(stretched_m.group('h')) + # yt:stretch may hold invalid ratio data (e.g. for Q39EVAstoRM ratio is 17:0). + # We will only process correct ratios. if w > 0 and h > 0: ratio = w / h for f in formats: |