Skip to main content

Web scraper that finds all pages on a domain

Project description

gleaner

A simple web scraper that finds all the pages on a domain using breadth-first search.

Installation

pipx install gleaner

Usage

glean https://example.com -o output.txt

This will

  • Start at given URL
  • Search through HTML to find pages on the same domain
  • Follow those links and repeat the process
  • Save all discovered URLs to output.txt

Options

  • -o, --output - Output file (default: urls.txt)

Limitations

  • Only follows <a>-tag links
  • Doesn't read robots.txt
  • No user-agent header
  • Duplication bug
  • Doesn't handle 429 errors (too many requests)
  • Doesn't parse sitemap.xml
  • No export formats beyond .txt (json? csv?)
  • Only works for entire domains. You can't glean an individual page and all sub-pages
  • Doesn't store progress for larger sites where scraping might last more than a few minutes
  • No concurrent processing

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

gleaner-0.1.2.tar.gz (4.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

gleaner-0.1.2-py3-none-any.whl (5.4 kB view details)

Uploaded Python 3

File details

Details for the file gleaner-0.1.2.tar.gz.

File metadata

  • Download URL: gleaner-0.1.2.tar.gz
  • Upload date:
  • Size: 4.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for gleaner-0.1.2.tar.gz
Algorithm Hash digest
SHA256 2504b18377b2ac41961b4ab59807c79bc355ddf1e25ced3eac5757b749ff4601
MD5 984099b79f958b3c53cf59de6f959e25
BLAKE2b-256 e9a88fcb625a6c950aad790e16d32a5434277a7de7996543baf7db02ce3d7a53

See more details on using hashes here.

File details

Details for the file gleaner-0.1.2-py3-none-any.whl.

File metadata

  • Download URL: gleaner-0.1.2-py3-none-any.whl
  • Upload date:
  • Size: 5.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for gleaner-0.1.2-py3-none-any.whl
Algorithm Hash digest
SHA256 32d4036f29918dc6120080310a0eaa6c7b0311f834429c8933024b76aacda70f
MD5 e7e5466b44ab9f944435fbaaccbc40c1
BLAKE2b-256 4c5b4b06c9201d867ad991f9d9229e7c27a6753655829072c9388e631976ddf2

See more details on using hashes here.

Supported by

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