Skip to content
New issue

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

fix issue #791 #782 #796

Merged
merged 4 commits into from
Oct 4, 2020
Merged

fix issue #791 #782 #796

merged 4 commits into from
Oct 4, 2020

Conversation

TonyBotongChu
Copy link
Contributor

下载bilibili playlist时,annie默认采用多线程。在Bilibili更新风控策略后,此类多线程下载被视为爬虫,从而导致用户ip被加入黑名单。ip加入黑名单期间,用户访问目标视频将返回http 412错误。
本次修改思路为:在下载bilibili视频时强制使用单线程。在解析bilibili视频时,强制忽略-n 参数,将下载线程数置为1。经测试,可以有效避免返回http 412错误。

Comment on lines 281 to 282
fmt.Printf("Warning: Multi thread download is no longer supported by BiliBili, use single thread instead.\n")
fmt.Printf("Thread Number: %d\n", option.ThreadNumber)
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Basically LGTM, but I think this is unnecessary

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I agree that line 282 is unnessary. But I still insist that it may be confusing for users to see -n parameter not working as expected, so printing a warning is beneficial.
But overall you are the owner, so you can make the final decision.

Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

OK then, I'll keep it.

Botong Chu and others added 3 commits September 30, 2020 20:01
Copy link
Owner

@iawia002 iawia002 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM, thanks

@iawia002 iawia002 merged commit b772d13 into iawia002:master Oct 4, 2020
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants