cwlm / SJTU_AutoRun

上海交通大学自动跑步脚本
MIT License
49 stars 5 forks source link

脚本运行到更改字体大小步骤后出现异常退出 #41

Closed zaixiabalala closed 1 month ago

zaixiabalala commented 1 month ago

更改字体大小步骤后报错“criticalErr on restart function”

wfrfred commented 1 month ago

是否能够复现,如果可以请提供更多信息,如运行环境和截图等

zaixiabalala commented 1 month ago

在运行sjtuautorun项目时,遇到了以下错误:

[INFO 19:01:13 sjtuautorun] resolution:(1080, 1920) [WARNING 19:01:13 sjtuautorun] ===================WARNING===================
[WARNING 19:01:13 sjtuautorun] No PLAN_ROOT specified, default value E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\data\plans will be used
[WARNING 19:01:13 sjtuautorun] ====================END====================
[DEBUG 19:01:31 sjtuautorun] ('click:', 1727089291.3981144, 887, 55) [DEBUG 19:01:36 sjtuautorun] ('click:', 1727089296.4209461, 99, 371) [DEBUG 19:01:37 sjtuautorun] ('click:', 1727089297.8714328, 122, 475) [DEBUG 19:01:39 sjtuautorun] ('click:', 1727089299.1857736, 76, 46) [DEBUG 19:01:51 sjtuautorun] ('Emulator status', 'running')

正在 Ping www.sjtu.edu.cn [202.120.2.119] 具有 32 字节的数据: 来自 202.120.2.119 的回复: 字节=32 时间=3ms TTL=251 来自 202.120.2.119 的回复: 字节=32 时间=2ms TTL=251 来自 202.120.2.119 的回复: 字节=32 时间=4ms TTL=251 来自 202.120.2.119 的回复: 字节=32 时间=4ms TTL=251

202.120.2.119 的 Ping 统计信息: 数据包: 已发送 = 4,已接收 = 4,丢失 = 0 (0% 丢失), 往返行程的估计时间(以毫秒为单位): 最短 = 2ms,最长 = 4ms,平均 = 3ms Traceback (most recent call last): File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 63, in restart self.start() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 36, in start self.set_text_size() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 134, in set_text_size self.confirm(must_confirm=1, timeout=10) File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 101, in confirm raise ImageNotFoundErr("no confirm image found") sjtuautorun.constants.custom_exceptions.ImageNotFoundErr: no confirm image found

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 63, in restart self.start() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 36, in start self.set_text_size() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 134, in set_text_size self.confirm(must_confirm=1, timeout=10) File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 101, in confirm raise ImageNotFoundErr("no confirm image found") sjtuautorun.constants.custom_exceptions.ImageNotFoundErr: no confirm image found

During handling of the above exception, another exception occurred:

Traceback (most recent call last): File "e:\desktop\helpers\autorun.py", line 4, in timer = start_script() ^^^^^^^^^^^^^^ File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\scripts\main.py", line 76, in start_script timer = Timer(config, logger) ^^^^^^^^^^^^^^^^^^^^^ File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 24, in init self.start() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 30, in start self.restart() File "E:\86150\Anaconda3\envs\auto_run\Lib\site-packages\sjtuautorun\controller\run_timer.py", line 80, in restart raise CriticalErr("CriticalErr on restart function") sjtuautorun.constants.custom_exceptions.CriticalErr: CriticalErr on restart function

环境信息: 操作系统:Windows 11 Python 版本:Python 3.11.10 Anaconda 版本:conda 24.7.1

备注: 多尝试几次有机会成功。但没有搞明白程序出现崩溃的原因

cwlm commented 1 month ago

已修复,请更新版本