[youtube] Improve multifeed videos extraction (Closes #8536)
authorSergey M․ <dstftw@gmail.com>
Fri, 12 Feb 2016 23:01:20 +0000 (05:01 +0600)
committerSergey M․ <dstftw@gmail.com>
Fri, 12 Feb 2016 23:01:20 +0000 (05:01 +0600)
youtube_dl/extractor/youtube.py

index 382d52cb6ca0da1a81b6b3c5efb6a29641794e6d..97d6219072d988e5ed16ad0277e18e69144fc7d6 100644 (file)
@@ -1196,9 +1196,12 @@ class YoutubeIE(YoutubeBaseInfoExtractor):
             if not self._downloader.params.get('noplaylist'):
                 entries = []
                 feed_ids = []
-                multifeed_metadata_list = compat_urllib_parse_unquote_plus(video_info['multifeed_metadata_list'][0])
+                multifeed_metadata_list = video_info['multifeed_metadata_list'][0]
                 for feed in multifeed_metadata_list.split(','):
-                    feed_data = compat_parse_qs(feed)
+                    # Unquote should take place before split on comma (,) since textual
+                    # fields may contain comma as well (see
+                    # https://github.com/rg3/youtube-dl/issues/8536)
+                    feed_data = compat_parse_qs(compat_urllib_parse_unquote_plus(feed))
                     entries.append({
                         '_type': 'url_transparent',
                         'ie_key': 'Youtube',