yutto-dev / yutto

:ice_cube: 一个可爱且任性的 B 站视频下载器(bilili V2)
GNU General Public License v3.0
1.06k stars 90 forks source link

🐛 响应数据无 data 域 #313

Closed pecliu closed 1 month ago

pecliu commented 1 month ago

问题简述

DEBUG  Fetch json: https://api.bilibili.com/x/web-interface/nav
 大会员  成功以大会员身份登录~
 DEBUG  ffmpeg -codecs
 DEBUG  ffmpeg -encoders
 DEBUG  ffmpeg -codecs
 DEBUG  ffmpeg -encoders
 DEBUG  Fetch json: https://api.bilibili.com/x/web-interface/nav
 DEBUG  Get redircted url: https://space.bilibili.com/107256/favlist?fid=2788160456&ftype=create
 DEBUG  Fetch json: https://api.bilibili.com/x/web-interface/nav
 DEBUG  Fetch json: https://api.bilibili.com/x/v3/fav/folder/info?media_id=2788160456
 DEBUG  Touch url: https://www.bilibili.com
 DEBUG  Fetch json: https://api.bilibili.com/x/space/wbi/acc/info
 收藏夹  临时下载
 DEBUG  Fetch json: https://api.bilibili.com/x/v3/fav/resource/ids?media_id=2788160456
 DEBUG  Fetch json: http://api.bilibili.com/x/web-interface/view?aid=&bvid=BV1NytGezEgV
Traceback (most recent call last):
  File "/opt/homebrew/bin/yutto", line 8, in <module>
    sys.exit(main())
             ^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/__main__.py", line 72, in main
    run(args_list)
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/utils/funcutils/as_sync.py", line 39, in sync_func
    return asyncio.run(async_func(*args, **kwargs))
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/python@3.12/3.12.6/Frameworks/Python.framework/Versions/3.12/lib/python3.12/asyncio/runners.py", line 194, in run
    return runner.run(main)
           ^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/python@3.12/3.12.6/Frameworks/Python.framework/Versions/3.12/lib/python3.12/asyncio/runners.py", line 118, in run
    return self._loop.run_until_complete(task)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/python@3.12/3.12.6/Frameworks/Python.framework/Versions/3.12/lib/python3.12/asyncio/base_events.py", line 687, in run_until_complete
    return future.result()
           ^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/__main__.py", line 314, in run
    download_list = await extractor(client, args)
                    ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/extractor/_abc.py", line 51, in __call__
    return await self.extract(client, args)
           ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/extractor/favourites.py", line 53, in extract
    ugc_video_list = await get_ugc_video_list(client, avid)
                     ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/api/ugc_video.py", line 130, in get_ugc_video_list
    video_info = await get_ugc_video_info(client, avid)
                 ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "/opt/homebrew/Cellar/yutto/2.0.0b42/libexec/lib/python3.12/site-packages/yutto/api/ugc_video.py", line 93, in get_ugc_video_info
    assert res_json_data is not None, "响应数据无 data 域"
           ^^^^^^^^^^^^^^^^^^^^^^^^^
AssertionError: 响应数据无 data 域

复现方式

yutto --vip-strict -b -n 1 --debug "https://space.bilibili.com/107256/favlist?fid=2788160456&ftype=create" -c "123"

值得注意的是,视频直接单独下载是可以的,但是放到收藏夹,然后从收藏夹批量下载时就会报错。上面时我私人收藏夹,里面就放了以下这一个视频。 https://www.bilibili.com/video/BV1GZ421L7Le/

另外,收藏夹里放其他视频是可以正常批量下载。但只要包含了上面这个视频,就解析失败

环境信息

额外信息

No response

一点点的自我检查

pecliu commented 1 month ago

忽略,不是这个视频的问题。是在我的收藏夹里有了一个隐藏的视频。是 b 站自己的 bug(收藏夹数量显示 1,但是实际列表拉出来是空的,永远删不掉)