yt-dlp: [bilibili] Cannot download videos with 1080p resolution
DO NOT REMOVE OR SKIP THE ISSUE TEMPLATE
- I understand that I will be blocked if I remove or skip any mandatory* field
Checklist
- I’m reporting a broken site
- I’ve verified that I’m running yt-dlp version 2022.11.11 (update instructions) or later (specify commit)
- I’ve checked that all provided URLs are playable in a browser with the same IP and same login details
- I’ve checked that all URLs and arguments with special characters are properly quoted or escaped
- I’ve searched the bugtracker for similar issues including closed ones. DO NOT post duplicates
- I’ve read the guidelines for opening an issue
- I’ve read about sharing account credentials and I’m willing to share it if required
Region
all
Provide a description that is worded well enough to be understood
Videos with resolution only up to 720p can be downloaded in 720p, but videos with resolution of 1080p or higher cannot be downloaded, not even those below 720p. In other issues, it is assumed that the difference is whether the account is Premier or not, but even regular members who are not Premier can watch 1080p. Only downloading is not possible.
Provide verbose output that clearly demonstrates the problem
- Run your yt-dlp command with -vU flag added (
yt-dlp -vU <your command line>
) - Copy the WHOLE output (starting with
[debug] Command-line config
) and insert it below
Complete Verbose Output
>yt-dlp -vU https://www.bilibili.com/video/BV1Dx411n7Pg?p=32
[debug] Command-line config: ['-vU', 'https://www.bilibili.com/video/BV1Dx411n7Pg?p=32']
[debug] Encodings: locale cp932, fs utf-8, pref cp932, out utf-8, error utf-8, screen utf-8
[debug] yt-dlp version 2022.11.11 [8b64402] (win_exe)
[debug] Python 3.8.10 (CPython AMD64 64bit) - Windows-10-10.0.19045-SP0 (OpenSSL 1.1.1k 25 Mar 2021)
[debug] exe versions: ffmpeg N-109451-geb0455d646-20221225 (setts), ffprobe N-109451-geb0455d646-20221225
[debug] Optional libraries: Cryptodome-3.15.0, brotli-1.0.9, certifi-2022.09.24, mutagen-1.46.0, sqlite3-2.6.0, websockets-10.4
[debug] Proxy map: {}
[debug] Loaded 1723 extractors
[debug] Fetching release info: https://api.github.com/repos/yt-dlp/yt-dlp/releases/latest
Latest version: 2022.11.11, Current version: 2022.11.11
yt-dlp is up to date (2022.11.11)
[debug] [BiliBili] Extracting URL: https://www.bilibili.com/video/BV1Dx411n7Pg?p=32
[BiliBili] 1Dx411n7Pg: Downloading webpage
[BiliBili] BV1Dx411n7Pg: Extracting videos in anthology
[BiliBili] Format(s) 1080P 高清, 360P 流畅, 480P 清晰, 720P 高清 are missing; you have to login or become premium member to download them
[BiliBili] 13255517: Extracting chapters
ERROR: [BiliBili] BV1Dx411n7Pg_p32: No video formats found!; please report this issue on https://github.com/yt-dlp/yt-dlp/issues?q= , filling out the appropriate issue template. Confirm you are on the latest version using yt-dlp -U
Traceback (most recent call last):
File "yt_dlp\YoutubeDL.py", line 1485, in wrapper
File "yt_dlp\YoutubeDL.py", line 1582, in __extract_info
File "yt_dlp\YoutubeDL.py", line 1641, in process_ie_result
File "yt_dlp\YoutubeDL.py", line 2573, in process_video_result
File "yt_dlp\YoutubeDL.py", line 1035, in raise_no_formats
yt_dlp.utils.ExtractorError: [BiliBili] BV1Dx411n7Pg_p32: No video formats found!; please report this issue on https://github.com/yt-dlp/yt-dlp/issues?q= , filling out the appropriate issue template. Confirm you are on the latest version using yt-dlp -U
About this issue
- Original URL
- State: open
- Created 2 years ago
- Comments: 22 (9 by maintainers)
Interesting. I merged the two extraction tactics in my yt-dl back-port and got this:
The
best
format gives this mpv output,whereas the 720p format gives this:
So the
best
format, which should be 1080p, is actually 720p and missing the last 20:12 of the video. In fact the “1080p” video has 5 parts @ 720p. Initially, such multi-part formats could be skipped.The 4 video and 3 audio formats that yt-dlp finds for the video above are indeed the ones in the JSON assigned to
window.__playinfo__
when the page is loaded in a non-JS browser. These are sent under thedash
key.Whereas the original video has just the
flv480
combined format, under thedurl
key.To get the full range of formats the extractor will need to load some API URL(s) to get the link for each of the formats listed under the
support_formats
key (apart from the 3rd which was already found) as listed above.FFmpeg-Builds just got HEVC-over-FLV support. It would be interesting to test it on real-world examples, so if someone has premium access to BiliBili, your help would be greatly appreciated.
The yt-dl extractor uses http://interface.bilibili.com/v2/playurl but it’s quite confused about the various formats available. The yt-dlp extractor looks in the JSON sent in the page itself.