ausaki / subfinder

字幕查找器
MIT License
833 stars 96 forks source link

奇怪的问题 #9

Closed lilarcor closed 6 years ago

lilarcor commented 6 years ago

subfinder.py /abc/Mayhem.2017.1080p.WEB-DL.DD5.1.H264-FGT/Mayhem.2017.1080p.WEB-DL.DD5.1.H264-FGT.mkv 报错, 其他名字的mkv没问题,不知道是不是没找到而抱着个错误 Find 1 video

Exception in thread Thread-1: Traceback (most recent call last): File "/usr/local/lib/python3.6/threading.py", line 916, in _bootstrap_inner self.run() File "./subfinder.py", line 222, in run sub_info_list = getSubInfo(f, lang) File "./subfinder.py", line 146, in getSubInfo return res.json() File "/usr/local/lib/python3.6/site-packages/requests/models.py", line 892, in json return complexjson.loads(self.text, **kwargs) File "/usr/local/lib/python3.6/json/init.py", line 354, in loads return _default_decoder.decode(s) File "/usr/local/lib/python3.6/json/decoder.py", line 339, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/local/lib/python3.6/json/decoder.py", line 357, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)

lilarcor commented 6 years ago

再加一个 subfinder.py /abc/Transformers.The.Last.Knight.2017.REPACK.720p.BluRay.x264-WiKi 报错 Find 1 videos

Traceback (most recent call last): File "./subfinder.py", line 359, in main(path, output, threads, languages, recursive, compress) File "./subfinder.py", line 317, in main recursive, compress) File "./subfinder.py", line 284, in downloadManySubs for i in range(threads): TypeError: 'float' object cannot be interpreted as an integer

直接查找文件,过了 subfinder.py /abc/Transformers.The.Last.Knight.2017.REPACK.720p.BluRay.x264-WiKi/Transformers.The.Last.Knight.2017.REPACK.720p.BluRay.x264-WiKi.mkv

ausaki commented 6 years ago

第一个错误应该是接口异常,没有正确返回json数据。你可以再试试。 第二个错误我提交新的代码了。

lilarcor commented 6 years ago

/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py /mnt/zfsrz2/share/downloads/movie/The.Hobbit.1-3.2012-2014.Extended.Edition.BluRay.1080p.DTS-HD.MA.7.1.2Audio.x265-EPiC/ Find 3 videos 一样,找了哈利波特的 Exception in thread Thread-1: Traceback (most recent call last): File "/usr/local/lib/python3.6/threading.py", line 916, in _bootstrap_inner self.run() File "/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py", line 223, in run sub_info_list = getSubInfo(f, lang) File "/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py", line 147, in getSubInfo return res.json() File "/usr/local/lib/python3.6/site-packages/requests/models.py", line 892, in json return complexjson.loads(self.text, **kwargs) File "/usr/local/lib/python3.6/json/init.py", line 354, in loads return _default_decoder.decode(s) File "/usr/local/lib/python3.6/json/decoder.py", line 339, in decode obj, end = self.raw_decode(s, idx=_w(s, 0).end()) File "/usr/local/lib/python3.6/json/decoder.py", line 357, in raw_decode raise JSONDecodeError("Expecting value", s, err.value) from None json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)


Finish.find 0 subtitles,0 sucessed,0 failed,0 files not found subtitle

找变形金刚 /mnt/zfsrz2/bak/Scripts/transmission/subfinder.py /mnt/zfsrz2/share/downloads/movie/01del/Transformers.The.Last.Knight.2017.REPACK.720p.BluRay.x264-WiKi/ Find 2 videos

Exception in thread Thread-1: Traceback (most recent call last): File "/usr/local/lib/python3.6/threading.py", line 916, in _bootstrap_inner self.run() File "/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py", line 223, in run sub_info_list = getSubInfo(f, lang) File "/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py", line 134, in getSubInfo filehash = computerVideoHash(videofile) File "/mnt/zfsrz2/bak/Scripts/transmission/subfinder.py", line 106, in computerVideoHash fp.seek(pos, 0) OSError: [Errno 22] Invalid argument


Finish.find 0 subtitles,0 sucessed,0 failed,0 files not found subtitle

ausaki commented 6 years ago

你熟悉python吗?建议你自己调试一下。 我这边无法复现json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)OSError: [Errno 22] Invalid argument这两个错误

lilarcor commented 6 years ago

我初学,我觉得可能和我系统变量有关系,有进展我更新你。谢谢你的回复