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
Python 版本: 3.12.2
模块版本: 16.3.0
运行环境: MacOS
大佬们2025快乐!
虽然能正常跑通,但还是有些不知道算不算问题的问题,如下:
async def get_comments()
栗子🌰:b站显示37条,count提示40条,实际默认收集输出14条
def flatten_comment(comment): # 展平单个评论 flattened_comment = { "uname": comment["member"]["uname"], "message": comment["content"]["message"], "like": comment["like"], "ctime": comment["ctime"], "IP location": comment['reply_control']['location'] } return flattened_comment def extract_comments(comments): # 提取所有评论,包括子评论 all_comments = [] for comment in comments: all_comments.append(flatten_comment(comment)) if "replies" in comment and comment["replies"]: all_comments.extend(extract_comments(comment["replies"])) return all_comments
发现,大部分子评论可以收集,但少数类似这种回复已被删除或者不蓝了的回复就无法收集到。鉴于目前b站阿瓦隆经常吞人回复,所以有的视频下这种虚空索敌的评论还挺多,收集不到有些可惜TT。
如上两个问题,期待大佬们的解答,还有感谢大佬们的贡献,先给大家磕一个Orz
The text was updated successfully, but these errors were encountered:
No branches or pull requests
Python 版本: 3.12.2
模块版本: 16.3.0
运行环境: MacOS
大佬们2025快乐!
虽然能正常跑通,但还是有些不知道算不算问题的问题,如下:
async def get_comments()
方法时,默认输出的虽然仅为主评论,但count的时候会将所有(疑似还包含已删除的)子评论全部计入。发现,大部分子评论可以收集,但少数类似这种回复已被删除或者不蓝了的回复就无法收集到。鉴于目前b站阿瓦隆经常吞人回复,所以有的视频下这种虚空索敌的评论还挺多,收集不到有些可惜TT。
![image](https://private-user-images.githubusercontent.com/192097001/400826773-39387652-012e-4681-a502-e9ab375fd8b9.png?jwt=eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJpc3MiOiJnaXRodWIuY29tIiwiYXVkIjoicmF3LmdpdGh1YnVzZXJjb250ZW50LmNvbSIsImtleSI6ImtleTUiLCJleHAiOjE3Mzk0NTkzMDAsIm5iZiI6MTczOTQ1OTAwMCwicGF0aCI6Ii8xOTIwOTcwMDEvNDAwODI2NzczLTM5Mzg3NjUyLTAxMmUtNDY4MS1hNTAyLWU5YWIzNzVmZDhiOS5wbmc_WC1BbXotQWxnb3JpdGhtPUFXUzQtSE1BQy1TSEEyNTYmWC1BbXotQ3JlZGVudGlhbD1BS0lBVkNPRFlMU0E1M1BRSzRaQSUyRjIwMjUwMjEzJTJGdXMtZWFzdC0xJTJGczMlMkZhd3M0X3JlcXVlc3QmWC1BbXotRGF0ZT0yMDI1MDIxM1QxNTAzMjBaJlgtQW16LUV4cGlyZXM9MzAwJlgtQW16LVNpZ25hdHVyZT02MjViMDViMTc2NzVjMjFhMDc1YjM1MDY1N2FiZWNmZjBjODA1ZGI2ZGQzMmZkMDdhNzg1NjE5MDA1Y2E5OGM5JlgtQW16LVNpZ25lZEhlYWRlcnM9aG9zdCJ9.GdE58EHYrF6WKNPnO7m8raiuk8MZnmT53StmVOYWvoE)
如上两个问题,期待大佬们的解答,还有感谢大佬们的贡献,先给大家磕一个Orz
The text was updated successfully, but these errors were encountered: