Skip to main content

Generic crawling for web galleries

Project description

https://github.com/idlesign/gallerycrawler

release lic

Description

Generic crawling for galleries

  1. Crawler starts from gallery listing URL;

  2. It visits every details page mentioned on current listing page;

  3. It gathers information from each details page;

  4. It moves to the next listing URL.

  5. Etc.

from galerycrawler.toolbox import Crawler, dump

# Define crawler.
class MyCrawler(Crawler):

    selector_listing_next: str = '.page-next a'
    selector_listing_thumbnails: str = '.thumbnail img'
    selector_details: str = '.page-details a'
    selector_details_title: str = '.page-title'
    selector_details_img: str = '.image img'
    selector_details_author: str = '.image-author'

# Run dumping.
dump(
    crawler=MyCrawler,
    url='https://mysite.some/gallery/',
    fpath='dumped.html',
    probe=True,  # Use this to quick test your crawler
)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

gallerycrawler-0.1.0.tar.gz (7.0 kB view details)

Uploaded Source

Built Distribution

gallerycrawler-0.1.0-py2.py3-none-any.whl (8.1 kB view details)

Uploaded Python 2 Python 3

File details

Details for the file gallerycrawler-0.1.0.tar.gz.

File metadata

  • Download URL: gallerycrawler-0.1.0.tar.gz
  • Upload date:
  • Size: 7.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: Python-urllib/2.7

File hashes

Hashes for gallerycrawler-0.1.0.tar.gz
Algorithm Hash digest
SHA256 ce5d9a313c2cb1a53239aab13dc7ee039e9e1fa97a37c7e92d2fd163e6b44787
MD5 0f18ddc0aa204f7f13914a40926e5e46
BLAKE2b-256 8408a271ab768c38ae906531b1dd9b7845fab3a847eda1dd773581ceda825e9a

See more details on using hashes here.

File details

Details for the file gallerycrawler-0.1.0-py2.py3-none-any.whl.

File metadata

File hashes

Hashes for gallerycrawler-0.1.0-py2.py3-none-any.whl
Algorithm Hash digest
SHA256 65d7067fb463e6dee25e9ec081f75c9bb1938fae7fdad1c36ae332c370f381a3
MD5 38d598dda5699cbce5236f1048e8b37a
BLAKE2b-256 658c0f4bee660ac5412380c62b9dc32400732521989c6aaa0fb56865ae23335a

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page