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.23k stars 9.93k forks source link

BBC iPlayer downloading broken #17946

Closed supercilious closed 5 years ago

supercilious commented 5 years ago

Please follow the guide below


Make sure you are using the latest version: run youtube-dl --version and ensure your version is 2018.10.05. If it's not, read this FAQ entry and update. Issues with outdated version will be rejected.

Before submitting an issue make sure you have:

What is the purpose of your issue?


The following sections concretize particular purposed issues, you can erase any section (the contents between triple ---) not applicable to 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 ```):

Z:\data\youtube_dl>youtube-dl -f best --ffmpeg-location Z:\config\youtube_dl\ffmpeg-4.0.2-win64-shared\bin --no-check-certificate --proxy socks5://MNEME:1080 -v https://www.bbc.co.uk/iplayer/episode/b0bnfkqc/the-apprentice-series-14-2-comics
[debug] System config: []
[debug] User config: []
[debug] Custom config: []
[debug] Command-line args: ['-f', 'best', '--ffmpeg-location', 'Z:\\config\\youtube_dl\\ffmpeg-4.0.2-win64-shared\\bin', '--no-check-certificate', '--proxy', 'socks5://MNEME:1080', '-v', 'https://www.bbc.co.uk/iplayer/episode/b0bnfkqc/the-apprentice-series-14-2-comics']
[debug] Encodings: locale cp1252, fs mbcs, out cp850, pref cp1252
[debug] youtube-dl version 2018.10.05
[debug] Python version 3.4.4 (CPython) - Windows-10-10.0.17763
[debug] exe versions: ffmpeg 4.0.2, ffprobe 4.0.2
[debug] Proxy map: {'http': 'socks5://MNEME:1080', 'https': 'socks5://MNEME:1080'}
[bbc.co.uk] b0bnfkqc: Downloading video page
[bbc.co.uk] b0bnfkqc: Downloading playlist JSON
[bbc.co.uk] b0bnfknh: Downloading media selection XML
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading MPD manifest
[bbc.co.uk] b0bnfknh: Downloading MPD manifest
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading MPD manifest
[bbc.co.uk] b0bnfknh: Downloading MPD manifest
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[bbc.co.uk] b0bnfknh: Downloading m3u8 information
[debug] Invoking downloader on 'https://bbcfmt-ic-05427300-09fb49-vodhlsuklive.s.loris.llnwd.net/usp/auth/vod/piff_abr_full_hd/d1cf3a-b0bnfknh/vf_b0bnfknh_a934bfbf-450f-4a53-84ef-e0fc29dc5a98.ism/vf_b0bnfknh_a934bfbf-450f-4a53-84ef-e0fc29dc5a98-audio_eng=320000-video=5070000.m3u8'
[hlsnative] Downloading m3u8 manifest
[hlsnative] Total fragments: 460
[download] Destination: The Apprentice, Series 14, Comics-b0bnfknh.mp4
[download]   4.3% of ~2.29GiB at  2.10MiB/s ETA 01:18:38  Traceback (most recent call last):
  File "__main__.py", line 19, in <module>
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\__init__.py", line 472, in main
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\__init__.py", line 462, in _real_main
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 2001, in download
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 803, in extract_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 857, in process_ie_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 1635, in process_video_result
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 1908, in process_info
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 1847, in dl
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\common.py", line 364, in download
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\hls.py", line 144, in real_download
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\fragment.py", line 102, in _download_fragment
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\common.py", line 364, in download
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\http.py", line 341, in real_download
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\downloader\http.py", line 109, in establish_connection
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\YoutubeDL.py", line 2211, in urlopen
  File "C:\Python\Python34\lib\urllib\request.py", line 464, in open
  File "C:\Python\Python34\lib\urllib\request.py", line 482, in _open
  File "C:\Python\Python34\lib\urllib\request.py", line 442, in _call_chain
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\utils.py", line 1139, in https_open
  File "C:\Python\Python34\lib\urllib\request.py", line 1183, in do_open
  File "C:\Python\Python34\lib\http\client.py", line 1137, in request
  File "C:\Python\Python34\lib\http\client.py", line 1182, in _send_request
  File "C:\Python\Python34\lib\http\client.py", line 1133, in endheaders
  File "C:\Python\Python34\lib\http\client.py", line 963, in _send_output
  File "C:\Python\Python34\lib\http\client.py", line 898, in send
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\utils.py", line 1105, in connect
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\socks.py", line 270, in connect
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\socks.py", line 266, in _make_proxy
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\socks.py", line 235, in _setup_socks5
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\socks.py", line 131, in _recv_bytes
  File "C:\Users\dst\AppData\Roaming\Build archive\youtube-dl\rg3\tmp5xdqinp2\build\youtube_dl\socks.py", line 126, in recvall
EOFError: 4 bytes missing

BBC iPlayer support is very hit and miss. Some URLs work fine, others error out with this error message. The error is always "EOFError: 4 bytes missing" but it happens at different times on different attempts. I am unable to test whether this error still occurs without the SOCKS5 proxy as iPlayer only allows UK IP addresses to connect to its service.

dstftw commented 5 years ago

Almost definitely caused by your proxy.