Skip to content

Files

Latest commit

author
Payne
Nov 9, 2020
3722e5b · Nov 9, 2020

History

History
36 lines (22 loc) · 1.17 KB

README.md

File metadata and controls

36 lines (22 loc) · 1.17 KB

PowerSpider

PowerSpider基于requests、lxml、封装成简单的爬虫。将给您避免大量的重复工作

便捷易用的PowerSpider提供以下功能

  • 智能化解析编码(二进制、中文、英文更多)
  • 解放双手,开箱即用。

PowerSpider 原理可参见释放双手,封装爬虫

使用要求

  • Python 版本不低于3.6
  • gcc 正常且完成安装

安装依赖包

强烈推荐使用 Condavirtualenv 创建虚拟环境,Python 版本不低于 3.6。

运行示例

from powerspider.Download import downloader

print(downloader("https://www.baidu.com")[:100])

# 2020-11-09 16:08:35.365 | INFO     | powerspider.Download:downloader:7 - Scraping https://www.baidu.com
# <!DOCTYPE html>
# <!--STATUS OK--><html> <head><meta http-equiv=content-type content=text/html;charse
# 2020-11-09 16:08:37.744 | INFO     | powerspider.Download:downloader:18 - Redirect_URL: https://www.baidu.com/