youtube-dl fails on some videos with error: ValueError: dictionary update sequence element #0 has length 1; 2 is required #67

Closed
opened 2026-02-20 21:01:23 -05:00 by deekerman · 1 comment
Owner

Originally created by @Elizafox on GitHub (Mar 9, 2011).

On some videos, such as http://www.youtube.com/watch?v=21UP0frYg-E, youtube-dl generates the following error:

[elizabeth@ein ~]$ youtube-dl http://www.youtube.com/watch?v=21UP0frYg-E
--- 8< snip >8 ---
[youtube] 21UP0frYg-E: Extracting video information
Traceback (most recent call last):
  File "/usr/bin/youtube-dl", line 2985, in 
    retcode = fd.download(all_urls)
  File "/usr/bin/youtube-dl", line 604, in download
    ie.extract(url)
  File "/usr/bin/youtube-dl", line 844, in extract
    return self._real_extract(url)
  File "/usr/bin/youtube-dl", line 1083, in _real_extract
    url_map = dict(tuple(pair.split('|')) for pair in video_info['fmt_url_map'][0].split(','))
ValueError: dictionary update sequence element #0 has length 1; 2 is required

Having done some investigation into the issue, it appears video_info does not get returned with the fmt_url_map element on some videos.

Originally created by @Elizafox on GitHub (Mar 9, 2011). On some videos, such as http://www.youtube.com/watch?v=21UP0frYg-E, youtube-dl generates the following error: <pre> [elizabeth@ein ~]$ youtube-dl http://www.youtube.com/watch?v=21UP0frYg-E --- 8< snip >8 --- [youtube] 21UP0frYg-E: Extracting video information Traceback (most recent call last): File "/usr/bin/youtube-dl", line 2985, in <module> retcode = fd.download(all_urls) File "/usr/bin/youtube-dl", line 604, in download ie.extract(url) File "/usr/bin/youtube-dl", line 844, in extract return self._real_extract(url) File "/usr/bin/youtube-dl", line 1083, in _real_extract url_map = dict(tuple(pair.split('|')) for pair in video_info['fmt_url_map'][0].split(',')) ValueError: dictionary update sequence element #0 has length 1; 2 is required </pre> Having done some investigation into the issue, it appears video_info does not get returned with the fmt_url_map element on some videos.
Author
Owner

@rg3 commented on GitHub (Mar 9, 2011):

Closing as it's a dupe of #86.

@rg3 commented on GitHub (Mar 9, 2011): Closing as it's a dupe of #86.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/youtube-dl#67
No description provided.