kaffaljidhmah2 / pku_epidemic Goto Github PK
View Code? Open in Web Editor NEWPKU燕园云战疫自动填写器
PKU燕园云战疫自动填写器
使用conda环境和自带Python环境均提示json错误,具体错误为:
Traceback (most recent call last):
File "main.py", line 76, in <module>
token = json.loads(r.text)['token']
File "/usr/local/Cellar/[email protected]/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/json/__init__.py", line 357, in loads
return _default_decoder.decode(s)
File "/usr/local/Cellar/[email protected]/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/json/decoder.py", line 337, in decode
obj, end = self.raw_decode(s, idx=_w(s, 0).end())
File "/usr/local/Cellar/[email protected]/3.8.5/Frameworks/Python.framework/Versions/3.8/lib/python3.8/json/decoder.py", line 355, in raw_decode
raise JSONDecodeError("Expecting value", s, err.value) from None
json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
需要post数据要加上
"jkm":""
昨天IAAA认证方式好像有变化,现在服务器那边好像会对请求头进行筛查,还得有完整的cookie(先请求https://iaaa.pku.edu.cn/iaaa/oauth.jsp?appID=portal2017&appName=%E5%8C%97%E4%BA%AC%E5%A4%A7%E5%AD%A6%E6%A0%A1%E5%86%85%E4%BF%A1%E6%81%AF%E9%97%A8%E6%88%B7%E6%96%B0%E7%89%88&redirectUrl=https://portal.pku.edu.cn/portal2017/ssoLogin.do
获得cookie ),IAAA才给token,获得token后请求ssologin,之后发每个请求服务器那边似乎都会对请求头进行筛查,否则服务器就不响应。兄弟你有什么解决办法吗😄
少了这一项
'dqszdgbm' = '156'
应该是当前所在地国家代码
Python 3.6.6 Windows10
报错提示为:
C:\Users\Thinkpad\Downloads\Compressed\pku_epidemic-master>python main.py
Traceback (most recent call last):
File "main.py", line 76, in
token = json.loads(r.text)['token']
File "C:\Users\Thinkpad\AppData\Local\Programs\Python\Python36\lib\json_init_.py", line 354, in loads
return _default_decoder.decode(s)
File "C:\Users\Thinkpad\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\Thinkpad\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)
"dwdzxx":"" , //定位地址信息
"dwjd":"",//定位经度
"dwwd":"",//定位纬度
"simstoken":"", //手机SIM卡的token
"jkm":"",//健康码
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.