diff options
author | Parmjit Virk <pvirk@mts.net> | 2018-08-30 14:32:35 -0500 |
---|---|---|
committer | Sergey M <dstftw@gmail.com> | 2018-08-31 02:32:35 +0700 |
commit | 14b7a24c19d70ec172eaedf799bcf81445ac9403 (patch) | |
tree | 27c554c31dc890dd5ff4018232328b4673fecca3 /youtube_dl/extractor | |
parent | 73f3bdbeb4b62a1286bcd74fdd1d5741740ea845 (diff) |
[bandcamp] Extract track_number (closes #17266)
Diffstat (limited to 'youtube_dl/extractor')
-rw-r--r-- | youtube_dl/extractor/bandcamp.py | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/youtube_dl/extractor/bandcamp.py b/youtube_dl/extractor/bandcamp.py index b8514734d..bc4c5165a 100644 --- a/youtube_dl/extractor/bandcamp.py +++ b/youtube_dl/extractor/bandcamp.py @@ -44,6 +44,17 @@ class BandcampIE(InfoExtractor): 'title': 'Ben Prunty - Lanius (Battle)', 'uploader': 'Ben Prunty', }, + }, { + 'url': 'https://relapsealumni.bandcamp.com/track/hail-to-fire', + 'info_dict': { + 'id': '2584466013', + 'ext': 'mp3', + 'title': 'Hail to Fire', + 'track_number': 5, + }, + 'params': { + 'skip_download': True, + }, }] def _real_extract(self, url): @@ -82,6 +93,7 @@ class BandcampIE(InfoExtractor): 'thumbnail': thumbnail, 'formats': formats, 'duration': float_or_none(data.get('duration')), + 'track_number': int_or_none(data.get('track_num')), } else: raise ExtractorError('No free songs found') |