diff --git a/main.py b/main.py index e17b90f..9efc864 100644 --- a/main.py +++ b/main.py @@ -157,6 +157,16 @@ class BiliWebCrawler: elif isinstance(honors, str): honor_data.append({'desc': honors}) + # 获取staff列表 + try: + staff= video_data.get('staff', []) + if len(staff)>0: + is_unity_up = True + else: + is_unity_up = False + except Exception as e: + is_unity_up = False + info = { 'BV号': self.bvid, 'title': video_data.get('title', ''), @@ -174,6 +184,7 @@ class BiliWebCrawler: '发布时间': time.strftime('%Y-%m-%d %H:%M:%S', time.localtime(video_data.get('pubdate', 0))), '分区': video_data.get('tname', ''), '标签': tag_data, + '是否为联合投稿': is_unity_up, '视频方向': self._get_video_orientation(video_data.get('dimension', {})), '视频最高分辨率': resolution_str, '视频类型': ["","自制", "转载"][video_data.get('copyright', 0)], @@ -292,7 +303,7 @@ class BiliWebCrawler: }) return danmaku - def get_comments(self, max_pages=1000): + def get_comments(self, max_pages=5): """获取热门评论,仅保留一级评论""" if not self.aid: send_notification("未找到视频 ID,无法获取评论数据。")