We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
System infomation: [ ] ( Windows10 64bit, MacOS 10.13.6, Ubuntu 18.04.3 amd64, ... ) Python version: [ ] ( run python3 --version ) AutoElective version: [ ] ( run python3 main.py --version )
python3 --version
python3 main.py --version
[course:general2]
name = 中国近现代史纲要 class = 5 school = 马克思主义学院
[course:general3]
name = 社会性别研究 class = 1 school = 社会学系
在使用过程中会有UnexceptedHTMLFormat encountered
[INFO] loop, 15:23:18, [INFO] loop, 15:23:18, > Current client: 1 (qsize: 2) [INFO] loop, 15:23:18, > Client expired time: 2021-03-07 15:26:30 [INFO] loop, 15:23:18, User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.89 Safari/537.36 [INFO] loop, 15:23:18, [INFO] loop, 15:23:18, Get SupplyCancel page 1 [INFO] loop, 15:23:19, Page dump to elective.get_SupplyCancel_1615101799306.html [ERROR] loop.error, 15:23:19, [104] unable to parse HTML content [WARNING] loop, 15:23:19, UnexceptedHTMLFormat encountered
如有必要,提供复现的步骤
The text was updated successfully, but these errors were encountered:
应该返回的是一个空页面,你可以看一下 log/web/${username}/elective.get_SupplyCancel_1615101799306.html 里面是什么
log/web/${username}/elective.get_SupplyCancel_1615101799306.html
这个问题和 #44 相同
Sorry, something went wrong.
不好意思,之前没有仔细研究这个问题 ...... 现在报这个错误是因为选课网改了 HTML 的结构,导致会话超时的错误没有被正确捕获,如下修改代码可以暂时解决这个问题
修改 parser.py 中 get_errInfo 函数,添加对 "提示:" 的识别
parser.py
get_errInfo
assert strong.tag == 'strong' and strong.text in ('出错提示:', '提示:')
修改 hook.py 中 check_elective_title 函数,添加对 "系统提示" 的识别
hook.py
check_elective_title
if title in ("系统异常", "系统提示"):
其它错误提示的格式有可能也变了, 但我目前暂时还没遇到与此类似的问题
No branches or pull requests
Check List
Version / Environment
System infomation: [ ] ( Windows10 64bit, MacOS 10.13.6, Ubuntu 18.04.3 amd64, ... )
Python version: [ ] ( run
python3 --version
)AutoElective version: [ ] ( run
python3 main.py --version
)Config
[course:general2]
name = 中国近现代史纲要
class = 5
school = 马克思主义学院
[course:general3]
name = 社会性别研究
class = 1
school = 社会学系
Issue Description
What
在使用过程中会有UnexceptedHTMLFormat encountered
Console Log
[INFO] loop, 15:23:18,
[INFO] loop, 15:23:18, > Current client: 1 (qsize: 2)
[INFO] loop, 15:23:18, > Client expired time: 2021-03-07 15:26:30
[INFO] loop, 15:23:18, User-Agent: Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/62.0.3202.89 Safari/537.36
[INFO] loop, 15:23:18,
[INFO] loop, 15:23:18, Get SupplyCancel page 1
[INFO] loop, 15:23:19, Page dump to elective.get_SupplyCancel_1615101799306.html
[ERROR] loop.error, 15:23:19, [104] unable to parse HTML content
[WARNING] loop, 15:23:19, UnexceptedHTMLFormat encountered
Reproduce
如有必要,提供复现的步骤
The text was updated successfully, but these errors were encountered: