Comments (3)
我发现问题在于有些课程的margint10
没有title
属性,因此在执行以下程序时会报错:
_course_detail["desc"] = course.select_one("p.margint10").attrs["title"]
这个属性在后续内容中没有被使用到,因此可以采用异常处理的手段来避免程序中断,修改后的内容如下:
try:
_course_detail["desc"] = course.select_one("p.margint10").attrs["title"]
except:
_course_detail["desc"] = “无”
from chaoxing.
我尝试了python main.py
和python main.py -c config.ini
两种方法,都是同样的结果(如上方“代码报错截图所示”)
所使用的系统:Ubuntu22.04.4-desktop
所使用的python环境:miniconda
from chaoxing.
我在Window10中尝试运行,也是一样的错误
from chaoxing.
Related Issues (20)
- 大佬,能写一个刷智慧职教慕课的程序吗?
- [BUG反馈]出现无权访问错误 HOT 1
- [BUG反馈]出现异常章节,代码不可刷,网页端可看 HOT 6
- [BUG反馈]章节任务点读取成功后程序直接退出 HOT 5
- [BUG反馈]
- [BUG反馈]无法获取课程列表
- [解决办法]cannot import name 'JSONDecodeError' from 'requests.exceptions'
- [BUG反馈] HOT 2
- [BUG反馈] HOT 1
- [BUG反馈] HOT 1
- 提议 HOT 1
- [BUG反馈] KeyError: 'type' HOT 1
- [BUG反馈] python3 main.py -c config.ini 报错 HOT 1
- [BUG反馈]直播课没法刷 HOT 1
- 你好,想问一下,后期可以增加一个题库,刷课堂作业嘛? HOT 1
- [BUG反馈]releases文件需要更新 HOT 1
- [BUG反馈]exe.输入账号密码登陆成功后闪退 HOT 3
- [BUG反馈]出现异常任务 HOT 4
- [BUG反馈] 403错误
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from chaoxing.