随笔分类 - 爬虫
摘要:介绍 Scrapy是一个基于Twisted的异步处理框架, 是纯Python实现的爬虫框架, 其架构清晰, 模块之间的耦合程度低, 可扩展性极强, 可以灵活完成各种需求. 我们只需要定制开发几个模块就可以轻松实现一个爬虫. Scrapy依赖twisted 安装 linux下, 目录结构 Scrapy
阅读全文
摘要:from bs4 import BeautifulSoup html_doc = """ The Dormouse's story asdf The Dormouse's story总共 f Once upon a time there were three little sisters; and their names were ...
阅读全文
摘要:爬虫的三个步骤: 1 下载源码 2 解析源码 3 保存数据 请求头: user-agent referer host cookie 特殊请起头 (查看上一次请求获取特殊请求头的值。) 请求体: - 原始数据 - 原始数据 + token - 密文 - 找算法 - 直接使用密文
阅读全文

浙公网安备 33010602011771号