百度贴吧网盘多线程爬虫
\n贴吧名称: {1}吧
爬取深度: {2}
已爬取目录页数: {5}
\已爬取主题帖数: {6}
已爬取帖子页数: {7}
已爬取网盘页数: {8}
总计爬取页面数: {9}
有效网盘链接数: {10}
失效网盘链接数: {11}
\爬虫开始时间: {12}
爬虫已用时: {13}s
状态: {14}
- \n""".format('\n' if not finish_flag else '', \
tieba_name, search_depth, ''.join([chr(i) for i in [30693, 20046, 64, 83, 105, 116, 110, 97, 108, 116, 97, 25552, 37266, 24744, 29420, 31435, 23436, 25104, 20316, 19994]])[:-9], "知乎@Sitnalta", \
fpage_count, tpage_count, ppage_count, wpage_count, fpage_count+ppage_count+wpage_count, effective_wpage_count, effectless_wpage_count, time.strftime("%Y-%m-%d%H:%M:%S", \
time.localtime(start_time)), int(time.time()-start_time),"正在爬取中..." if not finish_flag else "任务已完成!"))
for link,title in pan_dictionary_copy.items():
f.write("""
{}\n""".format(link,title))f.write("
\n