ytdl-org / youtube-dl

Command-line program to download videos from YouTube.com and other video sites
http://ytdl-org.github.io/youtube-dl/
The Unlicense
131.7k stars 9.97k forks source link

SonyLIV download error #16841

Closed theincognito-inc closed 6 years ago

theincognito-inc commented 6 years ago

What is the purpose of your issue?


If the purpose of this issue is a bug report, site support request or you are not completely sure provide the full verbose output as follows:

Add the -v flag to your command line you run youtube-dl with (youtube-dl -v <your command line>), copy the whole output and insert it here. It should look similar to one below (replace it with your log inserted between triple ```):

python -m youtube_dl -F -v https://www.sonyliv.com/details/highlights/5802755001001/Serbia-v-Brazil---Full-Match-Highlights---2018-FIFA-World-Cup-Russia™---27th-June,-2018 --no-geo-bypass
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-F', '-v', 'https://www.sonyliv.com/details/highlights/5802755001001/Serbia-v-Brazil---Full-Match-Highlights---2018-FIFA-World-Cup-Russia™---27th-June,-2018', '--no-geo-bypass']
[debug] Encodings: locale cp1252, fs utf-8, out utf-8, pref cp1252
[debug] youtube-dl version 2018.06.25
[debug] Git HEAD: 7b393f9cc
[debug] Python version 3.7.0 (CPython) - Windows-10-10.0.17134-SP0
[debug] exe versions: none
[debug] Proxy map: {}
[brightcove:new] ref:5802755001001: Downloading webpage
[brightcove:new] ref:5802755001001: Downloading JSON metadata
Traceback (most recent call last):
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\runpy.py", line 193, in _run_module_as_main
    "__main__", mod_spec)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\runpy.py", line 85, in _run_code
    exec(code, run_globals)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\__main__.py", line 19, in <module>
    youtube_dl.main()
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\__init__.py", line 472, in main
    _real_main(argv)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\__init__.py", line 462, in _real_main
    retcode = ydl.download(all_urls)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\YoutubeDL.py", line 2001, in download
    url, force_generic_extractor=self.params.get('force_generic_extractor', False))
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\YoutubeDL.py", line 803, in extract_info
    return self.process_ie_result(ie_result, download, extra_info)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\YoutubeDL.py", line 864, in process_ie_result
    extra_info=extra_info)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\YoutubeDL.py", line 792, in extract_info
    ie_result = ie.extract(url)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\common.py", line 501, in extract
    ie_result = self._real_extract(url)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\brightcove.py", line 718, in _real_extract
    json_data = self._download_json(api_url, video_id, headers=headers)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\common.py", line 858, in _download_json
    expected_status=expected_status)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\common.py", line 836, in _download_json_handle
    expected_status=expected_status)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\adobepass.py", line 1332, in _download_webpage_handle
    *args, **compat_kwargs(kwargs))
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\common.py", line 626, in _download_webpage_handle
    urlh = self._request_webpage(url_or_request, video_id, note, errnote, fatal, data=data, headers=headers, query=query, expected_status=expected_status)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\extractor\common.py", line 598, in _request_webpage
    return self._downloader.urlopen(url_or_request)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\YoutubeDL.py", line 2211, in urlopen
    return self._opener.open(req, timeout=self._socket_timeout)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\urllib\request.py", line 525, in open
    response = self._open(req, data)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\urllib\request.py", line 543, in _open
    '_open', req)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\urllib\request.py", line 503, in _call_chain
    result = func(*args)
  File "C:\Users\Windows\Downloads\youtube-dl\youtube_dl\utils.py", line 1101, in https_open
    req, **kwargs)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\urllib\request.py", line 1317, in do_open
    encode_chunked=req.has_header('Transfer-encoding'))
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\http\client.py", line 1229, in request
    self._send_request(method, url, body, headers, encode_chunked)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\http\client.py", line 1270, in _send_request
    self.putheader(hdr, value)
  File "C:\Users\Windows\AppData\Local\Programs\Python\Python37-32\lib\http\client.py", line 1202, in putheader
    values[i] = one_value.encode('latin-1')
UnicodeEncodeError: 'latin-1' codec can't encode character '\u2122' in position 125: ordinal not in range(256)

Description of your issue, suggested solution and other information

Earlier there was a fairplay encryption issue, which was fixed by @remitamine. Please look into the current issue.

theincognito-inc commented 6 years ago

@remitamine @dstftw

theincognito-inc commented 6 years ago

Hi.

Fixed it. It was an issue with some character in the URL. Changing the URL from "https://www.sonyliv.com/details/highlights/5802755001001/Serbia-v-Brazil---Full-Match-Highlights---2018-FIFA-World-Cup-Russia™---27th-June,-2018" to "https://www.sonyliv.com/details/highlights/5802755001001/" fixed the download.

Sorry for bothering.