jaysonlong / webvideo-downloader

Web video downloader for Bilibili, iQIYI, Tencent Video, MGTV and WeTV. 网站视频下载器,主要支持Bilibili、爱奇艺、腾讯视频、芒果TV、WeTV、愛奇藝台灣站。
1.1k stars 242 forks source link

Wetv只下载视频,字幕下载失败 #199

Open y50890080 opened 7 months ago

y50890080 commented 7 months ago

提示如下: Traceback (most recent call last): File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\dispatcher.py", line 167, in dispatch self.download(url, fileName, data) File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\dispatcher.py", line 139, in download targetFileName = self.handleSubtitles(subtitles, fileName, targetFileName, headers) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\dispatcher.py", line 108, in handleSubtitles self.downloader.downloadAll(subtitleUrls, subtitleNames, headers, self.hlsThreadCnt) File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\tools\downloader.py", line 174, in downloadAll self._waitUtilFinish() File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\tools\downloader.py", line 105, in _waitUtilFinish raise self.threadPool.exception File "C:\Users\Oct33\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\thread.py", line 58, in run result = self.fn(*self.args, *self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\tools\downloader.py", line 130, in _downloadRange raise self.threadPool.exception File "C:\Users\Oct33\AppData\Local\Programs\Python\Python312\Lib\concurrent\futures\thread.py", line 58, in run result = self.fn(self.args, **self.kwargs) ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ File "C:\Users\Oct33\Desktop\webvideo-downloader-master\downloader\tools\downloader.py", line 123, in _downloadRange rangeSize = rangeSize or int(response.headers['Content-Length'])


  File "C:\Users\Oct33\AppData\Local\Programs\Python\Python312\Lib\site-packages\requests\structures.py", line 52, in __getitem__
    return self._store[key.lower()][1]
           ~~~~~~~~~~~^^^^^^^^^^^^^
KeyError: 'content-length'