simple Spider
_ _ _____ _ _
(_) | | / ____| (_) | |
___ _ _ __ ___ _ __ | | ___ | (___ _ __ _ __| | ___ _ __
/ __| | '_ ` _ \| '_ \| |/ _ \ \___ \| '_ \| |/ _` |/ _ \ '__|
\__ \ | | | | | | |_) | | __/ ____) | |_) | | (_| | __/ |
|___/_|_| |_| |_| .__/|_|\___| |_____/| .__/|_|\__,_|\___|_|
| | | |
|_| |_|
Overview
A simple web crawling framework.Document
Getting Started
pip install simple-spiders
You should construst project.py to suit your needs
from crawler.spider import Spider
from crawler.writter import DataWriter
spider = Spider(
'https://movie.douban.com/subject/26810318/comments?start=0&limit=20&sort=new_score&status=P')
spider.start_crawl()
python project.py
Ctrl-C to stop
Referenced Libraries
Using requests as htmlDownloader
Using lxml as default htmlParser
Using csv provide feature that export file as csv type
Using xlwt provide feature that export file as excel type
Using xlsxwriter provide feature that export file as xexcel type
Usage
Project structure
- crawler/
- __init__.py
- test/
- htmlDownloder_test
- htmlParser_test
- requestManager_test
- writter_test
- logger_test
- spider_test
- htmlDownloder
- htmlParser
- requestManager
- writter
- logger
- spider
- main.py
License
This project is published open source under [] agreement.
Please maintain the open source release after modification and sign the
name of the original author. Thank you for your respect
If you need to apply this project for commercial purposes, please contact me( @pengr ) separately to obtain commercial authorization
Metadata
Release files for simple-spiders 0.1.5
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| simple-spiders-0.1.5.tar.gz | 11.4 kB | Without provenance | Details for simple-spiders-0.1.5.tar.gz |
Release files / simple-spiders-0.1.5.tar.gz
| Download URL | simple-spiders-0.1.5.tar.gz |
|---|---|
| Size | 11.4 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
7a97d0fe9fb38f6b794cadf5ddf0f9f5a68e2115b631bd7718a70350a44c646f
|
|
BLAKE2b-256 checksum How to use checksums |
50665063469f4d0f3eadbfc5b25511feafb2b9e07c0da891cd0be9b90f3701cc
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
Python-urllib/3.7
|
Security for simple-spiders 0.1.5
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.