Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ERROR: Error in output template: unsupported format character 'C' (0x43) at index 86 (encoding: 'UTF-8') #8450

Closed
tyrone-mt opened this issue Feb 7, 2016 · 7 comments

Comments

@tyrone-mt
Copy link

@tyrone-mt tyrone-mt commented Feb 7, 2016

Hi,

I am running the latest version of youtube-dl (youtube-dl is up-to-date (2016.02.05.1)). Getting the following:

ERROR: Error in output template: unsupported format character 'C' (0x43) at index 86 (encoding: 'UTF-8')
Traceback (most recent call last):
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 582, in prepare_filename
filename = tmpl % template_dict
ValueError: unsupported format character 'C' (0x43) at index 86

Kindly, could you please help.

@tedmx
Copy link

@tedmx tedmx commented Feb 7, 2016

Hello tyrone-mt, can you provide command line with arguments which produced the error?

@tyrone-mt
Copy link
Author

@tyrone-mt tyrone-mt commented Feb 7, 2016

exec("/usr/local/bin/youtube-dl --proxy 'xxx.xxx.xxx.xxx:xxxx' --verbose $website_url/$video_url -o PATH/videos/$video_url.mp4;");

@tedmx
Copy link

@tedmx tedmx commented Feb 7, 2016

Good, can you also tell the $website_url, $video_url, PATH values at the moment of call? Can be an issue with templating characters in "PATH/videos/$video_url.mp4" string.

@tyrone-mt
Copy link
Author

@tyrone-mt tyrone-mt commented Feb 7, 2016

It seems it's due some weird characters. Can this be solved somehow please?

url: http://www.dailymotion.com/video/x3qohmh_all-go%CE%B1ls-hd-m%CE%BFnch%CE%B5ngl%CE%B1db%CE%B1ch-5-1-w%CE%B5rd%CE%B5r-br%CE%B5m%CE%B5n-05-02-2016-hd_sport

If you copy/paste that link to your browser you would see some weird characters part of the url.

Thanks in advance.

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Feb 7, 2016

Post the full output of youtube-dl when run with --verbose option.

@tyrone-mt
Copy link
Author

@tyrone-mt tyrone-mt commented Feb 7, 2016

Downloaded http://www.xyz.com/videos/x3qojx3_0-3-kostas-mitroglou-b%CE%B5lenenses-v-b%CE%B5nfica-05-02-2016-hd_sport.mp4[debug] System config: []
[debug] User config: []
[debug] Command-line args: [u'--proxy', u'107.182.143.26:3128', u'--verbose', u'http://www.dailymotion.com/video/x3qojfj_0-2-jon%CE%B1s-b%CE%B5lenenses-v-b%CE%B5nfica-05-02-2016-hd_sport', u'-o', u'server_path/videos/x3qojfj_0-2-jon%CE%B1s-b%CE%B5lenenses-v-b%CE%B5nfica-05-02-2016-hd_sport.mp4']
[debug] Encodings: locale UTF-8, fs UTF-8, out None, pref UTF-8
[debug] youtube-dl version 2016.02.05.1
[debug] Python version 2.6.6 - Linux-2.6.32-573.12.1.el6.x86_64-x86_64-with-centos-6.7-Final
[debug] exe versions: ffmpeg 1.1.5, ffprobe 1.1.5
[debug] Proxy map: {u'http': u'107.182.143.26:3128', u'https': u'107.182.143.26:3128'}
WARNING: Failed to download m3u8 information: <urlopen error [Errno 104] Connection reset by peer>
ERROR: Error in output template: unsupported format character 'C' (0x43) at index 86 (encoding: 'UTF-8')
Traceback (most recent call last):
File "/usr/local/bin/youtube-dl/youtube_dl/YoutubeDL.py", line 582, in prepare_filename
filename = tmpl % template_dict
ValueError: unsupported format character 'C' (0x43) at index 86

@dstftw
Copy link
Collaborator

@dstftw dstftw commented Feb 7, 2016

Percent character % must start output template sequence. If you want to output percent literal itself you should double it %%.

@dstftw dstftw closed this Feb 7, 2016
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked pull requests

Successfully merging a pull request may close this issue.

None yet
3 participants
You can’t perform that action at this time.