From aebc2ddf89dccee594ea8bb862cb17cd43d266c8 Mon Sep 17 00:00:00 2001 From: Pyhtagodzilla <1670671958@qq.com> Date: Wed, 4 Jun 2025 15:43:21 +0800 Subject: [PATCH] change README file. --- README.md | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) diff --git a/README.md b/README.md index 55d9576..0e9ca62 100644 --- a/README.md +++ b/README.md @@ -1,15 +1,14 @@ # BUCT校园网自动认证 +用selenium实现的,主要放在树莓派上。 +使用systemd管理自启动。 -使用selenium实现,将edge的webdriver放入系统路径。准备使用树莓派进行自动定时认证。 +用crontab理论上也行。 -# 食用 -## 配置selenium环境 -### Windows -1. Python和pip安装,加入环境变量 -2. 用pip安装selenium库 -3. 下载相应浏览器版本的webdriver并存入环境变量 -4. run code -### Rasbian -1. 安装selenium库 -`sudo apt-get install python3-selenium` -他会**自行**安装**所有**需要的库、Webdriver、chronium等等。 \ No newline at end of file +由于用到了logging。所以service里面要加上`WorkingDirectory=/path/to/programe`。出错先找找权限问题。 + +--- + +现在还是有点问题。比如说没有连接wifi的情况下,request的get会报ssl error然后直接退出。except也不好用。 +我的解决方法就是service里面`Restart=always`,`RestartSec=60`。实测下来是能正常认证的。 + +用request来检测纯属闲的,本来还是拿selenium检测的。反正能跑管他呢。 \ No newline at end of file