We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent ea0fafc commit 4b2d6d5Copy full SHA for 4b2d6d5
.gitignore
@@ -1,3 +1,4 @@
1
__pycache__
2
venv/
3
-.pass
+.pass
4
+example_cookie.txt
learn_async.py
@@ -649,7 +649,12 @@ def clear(args):
649
def process_course(c, args):
650
# 处理单个课程的函数,用于多进程
651
build_global(args)
652
- login(args.username, args.password)
+ if args.cookie:
653
+ cookie.load(args.cookie, ignore_discard=True, ignore_expires=True)
654
+ args.login = get_page("/b/wlxt/kc/v_wlkc_xs_xktjb_coassb/queryxnxg") != err404
655
+ print("login successfully" if args.login else "login failed!")
656
+ else:
657
+ login(args.username, args.password)
658
659
c["_type"] = {"0": "teacher", "3": "student"}[c["jslx"]]
660
print("Sync " + c["xnxq"] + " " + c["kcm"])
0 commit comments