jimlee2002 / actions-wozaixiaoyuanpuncher Goto Github PK
View Code? Open in Web Editor NEW我在校园自动打卡程序:WoZaiXiaoYuanPuncher 的 Github Action 版。
License: Apache License 2.0
我在校园自动打卡程序:WoZaiXiaoYuanPuncher 的 Github Action 版。
License: Apache License 2.0
到点了不会自动运行 不知道怎么回事
麻烦写个教程,不然不知道每个密钥是什么东西
执行时报错,修改Cache name后执行一次正常,下一次自动执行又报错
Run python wzxy-dailyreport.py
找到cache文件,尝试使用jwsession打卡...
获取打卡列表中...
jwsession 无效,将尝试使用账号信息重新登录
使用账号信息登录成功
找到cache文件,正在更新cache中的jwsession...
Traceback (most recent call last):
File "/home/runner/work/WoZaiXiaoYuanPuncher-Actions/WoZaiXiaoYuanPuncher-Actions/wzxy-dailyreport.py", line 235, in
wzxy.PunchIn()
File "/home/runner/work/WoZaiXiaoYuanPuncher-Actions/WoZaiXiaoYuanPuncher-Actions/wzxy-dailyreport.py", line 91, in PunchIn
loginStatus = self.login()
File "/home/runner/work/WoZaiXiaoYuanPuncher-Actions/WoZaiXiaoYuanPuncher-Actions/wzxy-dailyreport.py", line 44, in login
self.setJwsession(jwsession)
File "/home/runner/work/WoZaiXiaoYuanPuncher-Actions/WoZaiXiaoYuanPuncher-Actions/wzxy-dailyreport.py", line 67, in setJwsession
item['jwsession'] = jwsession
TypeError: 'str' object does not support item assignment
Error: Process completed with exit code 1.
在配置USER_01时就遇见这个问题,后隔夜再尝试成功登陆了。在进行USER_02配置时又遇见此问题。environment与secrets配置正确。目前状态为USER_01可以正常打卡,USER_02显示打卡失败,登录信息错误。(严格遵守日志要求修改密码退出再运行脚本)
Run python wzxy-dailyreport.py
找到cache文件,尝试使用jwsession打卡...
获取打卡列表中...
正在进行:早打卡...
{'code': 7, 'message': '服务异常(7)'}
打卡失败
消息经 pushplus 推送成功
提示登录错误,请检查账号信息,但是账号信息已经更新过了,求教
详细输出log
截取片段
. . .
2021-12-30T08:35:01.7112565Z WZXY_STREET: ***
2021-12-30T08:35:01.7113189Z WZXY_AREACODE: ***
2021-12-30T08:35:01.7113794Z ##[endgroup]
2021-12-30T08:35:03.5714674Z 找到cache文件,尝试使用jwsession打卡...
2021-12-30T08:35:03.5715712Z 正在打卡...
2021-12-30T08:35:03.5716502Z 打卡成功
2021-12-30T08:35:03.5717474Z {'code': 999, 'msg': '无效的用户token', 'data': None}
2021-12-30T08:35:03.5718794Z 消息经 pushplus 推送失败,请检查错误信息
2021-12-30T08:35:03.5783290Z Post job cleanup.
. . .
根据实际抓包情况,自行添加了部分打卡数据(地区代码)
测试时将pushplus token直接写到了代码里
WZXY_AREACODE: ${{secrets.AREACODE}}
可以留一个联系方式吗
前两天因长时间未改动脚本而自动关闭,再次运行之后便无法自动打卡,但是手动运行可以打卡。(报错信息:打卡失败 发生未知错误)
当bark_token输入为http://domain/token/
即以斜杠结尾时,bark无法推送
if os.environ.get('BARK_TOKEN'):
# bark 推送
notifyToken = os.environ['BARK_TOKEN']
req = "{}/{}/{}".format(notifyToken, "⏰ 我在校园打卡(日检日报)结果通知", notifyResult)
requests.get(req)
print("消息经bark推送成功")
抓包的areacode打卡是不是不需要填
在我在校园小程序内成功打卡与日检但地址为一串字符,可能与Environment secrets存储内容相关
Run python wzxy-dailyreport.py
python wzxy-dailyreport.py
shell: /usr/bin/bash -e {0}
env:
pythonLocation: /opt/hostedtoolcache/Python/3.9.10/x64
LD_LIBRARY_PATH: /opt/hostedtoolcache/Python/3.9.10/x64/lib
DD_BOT_ACCESS_TOKEN:
DD_BOT_SECRET:
SCT_KEY:
BARK_TOKEN:
PUSHPLUS_TOKEN:
MIAO_CODE:
WZXY_USERNAME:
WZXY_PASSWORD:
WZXY_TEMPERATURE:
WZXY_LATITUDE:
WZXY_LONGITUDE:
WZXY_COUNTRY:
WZXY_CITY:
WZXY_DISTRICT:
WZXY_PROVINCE:
WZXY_TOWNSHIP:
WZXY_STREET:
WZXY_ANSWERS:
找不到cache文件,正在使用账号信息登录...
{'code': 1, 'message': '请输入用户名和密码'}
登录失败,请检查账号信息
登陆失败,请检查账号信息
怎么配置多账号打卡
Hi, In Actions-WoZaiXiaoYuanPuncher, inappropriate dependency versioning constraints can cause risks.
Below are the dependencies and version constraints that the project is using
requests==2.26.0
urllib3==1.26.7
pytz==2021.3
The version constraint == will introduce the risk of dependency conflicts because the scope of dependencies is too strict.
The version constraint No Upper Bound and * will introduce the risk of the missing API Error because the latest version of the dependencies may remove some APIs.
After further analysis, in this project,
The version constraint of dependency requests can be changed to >=0.7.0,<=2.24.0.
The version constraint of dependency requests can be changed to ==2.26.0.
The version constraint of dependency pytz can be changed to >=2011d,<=2013d.
The version constraint of dependency pytz can be changed to >=2011b,<=2022.1.
The above modification suggestions can reduce the dependency conflicts as much as possible,
and introduce the latest version as much as possible without calling Error in the projects.
The invocation of the current project includes all the following methods.
requests.get requests.session requests.post
pytz.timezone
WoZaiXiaoYuanPuncher self.setJwsession utils.processJson.write self.getJwsession hashlib.sha256.string_to_sign_enc.secret_enc.hmac.new.digest DD_BOT_SECRET.encode url.format self.login round temperature.split self.PunchIn utils.processJson WoZaiXiaoYuanPuncher.doPunchIn random.uniform hmac.new str json.dump requests.session url.requests.get.json int json.load os.environ.get self.getResult msg.json.dumps.encode headers.data.json.dumps.url.requests.post.json json.dumps format.encode random.seed open time.ctime headers.body.url.requests.post.json time.time urllib.parse.quote_plus base64.b64encode pytz.timezone datetime.datetime.now os.path.exists float urllib.parse.urlencode requests.get json.loads pytz.timezone.datetime.datetime.now.strftime print WoZaiXiaoYuanPuncher.login os.mkdir os.environ.cur_time.os.environ.encode utils.getRandomTemperature hashlib.sha256 WoZaiXiaoYuanPuncher.PunchIn file.close format WoZaiXiaoYuanPuncher.sendNotification utils.getCurrentTime temperature.find os.environ.cur_time.os.environ.encode.hashlib.sha256.hexdigest self.doPunchIn self.getSeq self.session.post requests.post utils.processJson.read
@developer
Could please help me check this issue?
May I pull a request to fix it?
Thank you very much.
健康打卡提示如下:
找不到cache文件,正在使用账号信息登录...
{'code': 1, 'message': '请输入用户名和密码'}
登录失败,请检查账号信息
登陆失败,请检查账号信息
日检日报提示如下:
Run python wzxy-dailyreport.py
找到cache文件,尝试使用jwsession打卡...
获取打卡列表中...
打卡失败:不在打卡时间段内
实在不好意思我改错仓库了,不小心在你的仓库提交了commit,抱歉抱歉orz
4.17号我在校园更新后,抓不到我在校园的包了。
小程序报错
Could not load the requested resource.
Error code: -202 (net::ERR_CERT_AUTHORITY_INVALID)
估计又更新了,晕,明天抓个包试试。
data当中的经纬度和街道、乡镇是否要对应,还是必须填写目前所处的位置的定位,我这里返回的信息为:未找到街道信息。
求解决方法,谢谢!!!
配置都正确,还是出现了错误
正在打卡...
{'code': 500, 'message': '服务出错(500)'}
打卡失败
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.