ValueError: dictionary update sequence element #0 has length 1; 2 is required #50

Closed
opened 2026-02-20 21:00:39 -05:00 by deekerman · 5 comments
Owner

Originally created by @rifter on GitHub (Jan 29, 2011).

The infamous error has reared its ugly head yet again:
ValueError: dictionary update sequence element #0 has length 1; 2 is required

This will show for any new videos you try to download. command line
options and output are pasted at the bottom.

I know this has happened many times before, but I can't find the
previous times in the issue tracker.
I downloaded what I think is the most recent snapshot (it said that
the commit was 9 hours ago) and the problem persists.
As I recall last time this happened you fixed it pretty quickly and it
had something to do with what youtube returns to you at some point in
your program.
One of these days I will have to dig into how this all works so I can
be more help in these situations.
Again thank you for a great program that is the basis for so much more.

$ ./youtube-dl -i -n -c -o %(uploader)s-%(stitle)s-%(id)s.%(ext)s
http://www.youtube.com/watch?v=oyxWLIJk-rU
[youtube] Setting language
[youtube] Logging in
[youtube] Confirming age
[youtube] oyxWLIJk-rU: Downloading video webpage
[youtube] oyxWLIJk-rU: Downloading video info webpage
[youtube] oyxWLIJk-rU: Extracting video information
Traceback (most recent call last):
File "./youtube-dl", line 2462, in
retcode = fd.download(all_urls)
File "./youtube-dl", line 481, in download
ie.extract(url)
File "./youtube-dl", line 711, in extract
return self._real_extract(url)
File "./youtube-dl", line 951, 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
$

Originally created by @rifter on GitHub (Jan 29, 2011). The infamous error has reared its ugly head yet again: ValueError: dictionary update sequence element #0 has length 1; 2 is required This will show for any new videos you try to download. command line options and output are pasted at the bottom. I know this has happened many times before, but I can't find the previous times in the issue tracker. I downloaded what I think is the most recent snapshot (it said that the commit was 9 hours ago) and the problem persists. As I recall last time this happened you fixed it pretty quickly and it had something to do with what youtube returns to you at some point in your program. One of these days I will have to dig into how this all works so I can be more help in these situations. Again thank you for a great program that is the basis for so much more. # $ ./youtube-dl -i -n -c -o %(uploader)s-%(stitle)s-%(id)s.%(ext)s http://www.youtube.com/watch?v=oyxWLIJk-rU [youtube] Setting language [youtube] Logging in [youtube] Confirming age [youtube] oyxWLIJk-rU: Downloading video webpage [youtube] oyxWLIJk-rU: Downloading video info webpage [youtube] oyxWLIJk-rU: Extracting video information Traceback (most recent call last): File "./youtube-dl", line 2462, in <module> retcode = fd.download(all_urls) File "./youtube-dl", line 481, in download ie.extract(url) File "./youtube-dl", line 711, in extract return self._real_extract(url) File "./youtube-dl", line 951, 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 $
Author
Owner

@rifter commented on GitHub (Jan 29, 2011):

Hmm.
This is not happening for all videos anymore apparently. I had a good run (or I guess bad) where all of them were doing this, but now some videos are working. The one above and several other cnn videos are not working. so maybe it is something weird about cnn's channel.

@rifter commented on GitHub (Jan 29, 2011): Hmm. This is not happening for all videos anymore apparently. I had a good run (or I guess bad) where all of them were doing this, but now some videos are working. The one above and several other cnn videos are not working. so maybe it is something weird about cnn's channel.
Author
Owner
@rifter commented on GitHub (Jan 29, 2011): Here are some videos that are giving this behaviour now: http://www.youtube.com/watch?v=spTHQU2Gkwc http://www.youtube.com/watch?v=Yp6hHXJRB2A http://www.youtube.com/watch?v=r_DHOdeuh7A http://www.youtube.com/watch?v=qKa-311uqgQ http://www.youtube.com/watch?v=oyxWLIJk-rU
Author
Owner

@rg3 commented on GitHub (Jan 29, 2011):

I am unable to reproduce the problem here. When I access any of those videos from my browser, I get "This video is not available in your country." and from youtube-dl I see the following:

$ youtube-dl -i -a tmp.txt
[youtube] Setting language
[youtube] spTHQU2Gkwc: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found
[youtube] Yp6hHXJRB2A: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found
[youtube] r_DHOdeuh7A: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found
[youtube] qKa-311uqgQ: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found
[youtube] oyxWLIJk-rU: Downloading video webpage
ERROR: unable to download video webpage: HTTP Error 404: Not Found
@rg3 commented on GitHub (Jan 29, 2011): I am unable to reproduce the problem here. When I access any of those videos from my browser, I get "This video is not available in your country." and from youtube-dl I see the following: ``` $ youtube-dl -i -a tmp.txt [youtube] Setting language [youtube] spTHQU2Gkwc: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found [youtube] Yp6hHXJRB2A: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found [youtube] r_DHOdeuh7A: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found [youtube] qKa-311uqgQ: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found [youtube] oyxWLIJk-rU: Downloading video webpage ERROR: unable to download video webpage: HTTP Error 404: Not Found ```
Author
Owner

@rg3 commented on GitHub (Jan 30, 2011):

Try the version released today. If no more reports are received, the issue will be closed.

@rg3 commented on GitHub (Jan 30, 2011): Try the version released today. If no more reports are received, the issue will be closed.
Author
Owner

@rg3 commented on GitHub (Feb 3, 2011):

Closed due to inability to reproduce and lack of more reports. Will reopen when if more information is available.

@rg3 commented on GitHub (Feb 3, 2011): Closed due to inability to reproduce and lack of more reports. Will reopen when if more information is available.
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#50
No description provided.