diff options
author | Sergey M․ <dstftw@gmail.com> | 2017-08-27 03:27:05 +0700 |
---|---|---|
committer | Sergey M․ <dstftw@gmail.com> | 2017-08-27 03:27:05 +0700 |
commit | 1ed4549942c34cce52b9c641cf9f532c38866149 (patch) | |
tree | 364076a399785df0327e6f584fecd8b9f4d4f333 /youtube_dl | |
parent | dd121cc1cab2f077cbf68ee432e83d4d094f0f9a (diff) |
[extractor/common] Extract format id from label attribute of source tag for HTML5 videos (#14034)
Diffstat (limited to 'youtube_dl')
-rw-r--r-- | youtube_dl/extractor/common.py | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/youtube_dl/extractor/common.py b/youtube_dl/extractor/common.py index b4af3f987..74d30ec50 100644 --- a/youtube_dl/extractor/common.py +++ b/youtube_dl/extractor/common.py @@ -2186,7 +2186,10 @@ class InfoExtractor(object): if is_plain_url: # res attribute is not standard but seen several times # in the wild - f['height'] = int_or_none(source_attributes.get('res')) + f.update({ + 'height': int_or_none(source_attributes.get('res')), + 'format_id': source_attributes.get('label'), + }) f.update(formats[0]) media_info['formats'].append(f) else: |