diff --git a/main.py b/main.py index 5a19ba8a..85695b38 100644 --- a/main.py +++ b/main.py @@ -87,7 +87,7 @@ def init_config(): jobs, job_info = chaoxing.get_job_list(course["clazzId"], course["courseId"], course["cpi"], point["id"]) # 发现未开放章节,回滚上一个任务重新完成一次 - if job_info['notOpen']: + if job_info.get('notOpen',False): __point_index -= 1 # 默认第一个任务总是开放的 continue @@ -119,6 +119,7 @@ def init_config(): elif job["type"] == "workid": logger.trace(f"识别到章节检测任务, 任务章节: {course['title']}") chaoxing.study_work(course, job,job_info) + __point_index += 1 logger.info("所有课程学习任务已完成") except BaseException as e: import traceback