Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

验证码错误 #12

Open
koko12131 opened this issue Nov 15, 2018 · 1 comment
Open

验证码错误 #12

koko12131 opened this issue Nov 15, 2018 · 1 comment

Comments

@koko12131
Copy link

我使用的是py3.6.1(64位) 将项目导入pycharm运行后得到以下错误

第1页

出现验证码
识别验证码为:1
验证码错误
识别验证码为:1

第1页

Traceback (most recent call last):
File "G:/coding/wenshu_spider-master/court.py", line 393, in
get_data(Param,Page,Order,Direction)
File "G:/coding/wenshu_spider-master/court.py", line 252, in get_data
json_data = json.loads(return_data)
File "C:\Users\Andrew\AppData\Local\Programs\Python\Python36\lib\json_init_.py", line 354, in loads
return _default_decoder.decode(s)
File "C:\Users\Andrew\AppData\Local\Programs\Python\Python36\lib\json\decoder.py", line 339, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "C:\Users\Andrew\AppData\Local\Programs\Python\Python36\lib\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)

@sixs
Copy link
Owner

sixs commented Nov 16, 2018

1、验证码识别已经失效了,把验证码识别和验证注释掉
2、返回的数据return_data不是json字符串,打印下看看是什么,然后加个条件判断

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants