[audiomack:album] Force video_id to be strings
authorYen Chi Hsuan <yan12125@gmail.com>
Fri, 10 Jun 2016 08:11:28 +0000 (16:11 +0800)
committerYen Chi Hsuan <yan12125@gmail.com>
Fri, 10 Jun 2016 08:11:28 +0000 (16:11 +0800)
Related: be6217b26142491232fb697b125015d45437832d

youtube_dl/extractor/audiomack.py

index a52d26cecd1e98f8d4a902ed4e8051a42e21e200..f3bd4d4447f559a8bd924f7d796a1a9faf24b9d3 100644 (file)
@@ -6,6 +6,7 @@ import time
 
 from .common import InfoExtractor
 from .soundcloud import SoundcloudIE
+from ..compat import compat_str
 from ..utils import (
     ExtractorError,
     url_basename,
@@ -136,7 +137,7 @@ class AudiomackAlbumIE(InfoExtractor):
                         result[resultkey] = api_response[apikey]
                 song_id = url_basename(api_response['url']).rpartition('.')[0]
                 result['entries'].append({
-                    'id': api_response.get('id', song_id),
+                    'id': compat_str(api_response.get('id', song_id)),
                     'uploader': api_response.get('artist'),
                     'title': api_response.get('title', song_id),
                     'url': api_response['url'],