卡在analysing weibos
Closed this issue · 6 comments
mrl998 commented
运行程序后卡在analysing weibos... 957/94738 一动不动
也试过把cookie加上去,效果差不多
貌似这种微博数量很多的用户都不能正常爬取相册,请问是什么原因呢?
nondanee commented
看了下卡在 analysing 是因为触发了微博反爬机制,返回了 418 i'm a teapot
需要等一会儿再爬
weiboPicDownloader/weiboPicDownloader.py
Line 181 in 055de3d
想稳定一点的话,这个 time.sleep(1) 间隔可以适当改长一点,不过分析过程会更慢
微博特别多的也没什么好办法,开在后台让它慢慢分析吧,一页小于 25 条好像也是限制了的
kybom commented
我今天也遇到了同样的问题,难道是微博的反扒机制升级了。
kybom commented
测试了一下最新版本
$ python weiboPicDownloader.py -f macs.txt -v
1/441 Wed Jan 23 16:39:59 2019
SNH48-▒¹ۻ▒ѽ 3050708243
finish analysis 1027/1095(#46)
practically get 1027 weibos, 2019 resources
all tasks done 2019/2019(100%)
successfull 2019, failed 0, total 2019
------------------------------
2/441 Wed Jan 23 16:41:31 2019
SNH48-▒▒▒▒ 3050709151
analysing weibos... 859/1977(#35)anti-scraping mechanism is triggered(#36)
practically get 859 weibos, 2806 resources
all tasks done 2806/2806(100%)
successfull 2802, failed 4, total 2806
automatic retry 1
all tasks done 4/4(100%)
successfull 4, failed 0, total 4
------------------------------
3/441 Wed Jan 23 16:43:07 2019
SNH48-▒▒▒▒▒▒ 3050731261
anti-scraping mechanism is triggered(#1)
practically get 0 weibos, 0 resources
------------------------------
4/441 Wed Jan 23 16:43:09 2019
SNH48-▒▒▒▒▒ 3050737061
anti-scraping mechanism is triggered(#1)
practically get 0 weibos, 0 resources
------------------------------
5/441 Wed Jan 23 16:43:13 2019
SNH48-▒▒˼ 3050742117
anti-scraping mechanism is triggered(#1)
practically get 0 weibos, 0 resources
nondanee commented
@mrl998
不包括转发的,但是 H5 版没有相册功能
直接解析相册的也有人做过
https://github.com/lincanbin/Sina-Weibo-Album-Downloader
https://github.com/Lodour/Weibo-Album-Crawler
这个项目真的只是个移植项目