最近经常分享python的文章,然后4月底总是有人问我有没有一起学党史脚本,刚开始我以为是大学生在线的那个,结果发给我一个小程序码,瞬间把我干懵了,因为我还没见过小程序刷分工具过,后面去网上逛了一圈,还真有一个能实现一起学党史网上答题对战自动化答题的python脚本,因为四月事情太多了,所以推到了今天试一试。
首先前往python官网下载python安装包,要选择适合自己电脑的,然后按照自己的需要安装好pyhton
输入下面的指令安装hashids,但是这步往往有建议警示,只需要将相应的模块升级成所需版本即可
pip install hashids
这时运行python脚本,有时会缺少requests模块,输入下面的命令安装,安装好再运行py看有没有缺的没有
pip install requests
可以通过Fiddler抓包device_info和user_id,或者直接填写我给的device_info,然后再通过小程序开启权限获取user_id,填入到py相应的地方里再运行,这样就成功了
{"albumAuthorized":true,"benchmarkLevel":-1,"bluetoothEnabled":false,"brand":"microsoft","cameraAuthorized":true,"fontSizeSetting":15,"language":"zh_CN","locationAuthorized":true,"locationEnabled":true,"microphoneAuthorized":true,"model":"microsoft","notificationAuthorized":true,"notificationSoundEnabled":true,"pixelRatio":1,"platform":"windows","power":100,"safeArea":{"bottom":692,"height":692,"left":0,"right":414,"top":0,"width":414},"screenHeight":736,"screenWidth":414,"statusBarHeight":20,"system":"Windows 10 x64","theme":"light","version":"7.0.9","wifiEnabled":true,"windowHeight":692,"windowWidth":414,"SDKVersion":"2.13.2","devicePixelRatio":1,"safeAreaInsets":{"top":0,"left":0,"right":0,"bottom":0}}
项目地址:Github PartyHistoryofLearning
本文只适合有一定电脑基础的人使用,如果有需要帮助请关注公众号“爱送福利的貔貅”回复“需要帮助”四字按照提示联系我。
如有疑问可留言评论
有没有视频讲解呢?
@捌玖拾 一直都有的哦