From ae03af5a50830f740c97d34c03e9f0a4ce884eec Mon Sep 17 00:00:00 2001 From: NianBroken Date: Mon, 15 Jul 2024 15:38:41 +0800 Subject: [PATCH] =?UTF-8?q?=E5=BD=93=E6=A3=80=E6=B5=8B=E5=88=B0=E9=AA=8C?= =?UTF-8?q?=E8=AF=81=E7=A0=81=E6=97=B6=EF=BC=8C=E5=BC=BA=E5=88=B6=E7=BB=93?= =?UTF-8?q?=E6=9D=9F=E7=A8=8B=E5=BA=8F=E3=80=82?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- scripts/user_login.py | 3 +++ 1 file changed, 3 insertions(+) diff --git a/scripts/user_login.py b/scripts/user_login.py index 0fab664..b69ac03 100644 --- a/scripts/user_login.py +++ b/scripts/user_login.py @@ -25,6 +25,8 @@ def login(url, username, password): if cookies == {}: lgn = student_client.login(username, password) if lgn["code"] == 1001: + sys.exit("你的教务系统登录需要验证码,因此你无法使用此项目。") + """ verify_data = lgn["data"] with open(os.path.abspath("kaptcha.png"), "wb") as pic: pic.write(base64.b64decode(verify_data.pop("kaptcha_pic"))) @@ -34,6 +36,7 @@ def login(url, username, password): pprint(ret) sys.exit() pprint(ret) + """ elif lgn["code"] != 1000: pprint(lgn) sys.exit()