Skip to main content

Weekend-hopper toolkit for ICN short-haul scouting

Project description

Awesome Cheap Flights

Awesome Cheap Flights logo

Weekend-hopper toolkit for spotting cheap ICN short-hauls without opening browser.

Highlights

  • Hidden-leg discovery merges with regular legs automatically.
  • Hidden-leg discovery only bridges a single intermediate stop.
  • Plans expand airport pools and date windows per leg.
  • Duplicate flights per journey leg collapse into a single row.
  • Progress logs now surface a sample flight summary per batch.
  • Automatic itinerary workbooks enumerate every leg combination with totals.
  • CSV rows expose variant metadata for hidden journeys.
  • Rich logging prints overview tables and elapsed minutes.

Examples

Example 1. Quick uvx run.

uvx awesome-cheap-flights@latest --config sample.config.yaml --plan sample-hop

Example 2. Local CLI run.

uv run python -m awesome_cheap_flights.cli --config sample.config.yaml --plan sample-hop

Example 3. macOS uv install.

curl -Ls https://astral.sh/uv/install.sh | sh
source "$HOME/.local/bin/env"
uvx awesome-cheap-flights@latest --config sample.config.yaml --plan sample-hop

Example 4. Windows uv install.

powershell -ExecutionPolicy Bypass -Command "iwr https://astral.sh/uv/install.ps1 -useb | iex"
uvx awesome-cheap-flights@latest --config sample.config.yaml --plan sample-hop

Example 5. Android uv install.

pkg update
pkg install curl python
curl -Ls https://astral.sh/uv/install.sh | sh
source "$HOME/.local/bin/env"
uvx awesome-cheap-flights@latest --config sample.config.yaml --plan sample-hop

After each run, open the CSV and sort by price.

Development mode

Run the CLI locally for iterative tweaks.

uv run python -m awesome_cheap_flights.cli --config config.yaml --output output/dev.csv
  • Copy sample.config.yaml into config.yaml before editing routes.
  • Update config.yaml to adjust places, paths, or windows.
  • Set UV_CACHE_DIR=$(pwd)/.cache/uv to isolate uv cache.
  • Omit --output to write timestamped files inside output/ automatically.
  • Combine CLI overrides with commas or repeated flags for airports.
  • Sample plan completes within five minutes on modern laptops.

Troubleshooting

  • Upgrade typing_extensions when imports complain about missing features.
  • Append --debug for full provider payload dumps during runs.
  • Press Ctrl+C to save draft CSV and resume later minutes.
  • Update to this revision if python -m awesome_cheap_flights.cli printed nothing.
  • Install openpyxl>=3.1 if itinerary workbooks fail to generate.

Configuration

  • Set schema_version: v2 to enable the DSL.
  • Fill defaults with currency, passenger count, and request minutes.
  • Request delay accepts fractional seconds for rate limiting.
  • Filters hold max_stops, include_hidden, and max_hidden_hops limits.
  • Departures allow per-leg max_stops overrides alongside date selectors.
  • Output directory and filename_pattern customize CSV targets.
  • Plans list places, path, departures, filters, and options blocks.
  • Options include include_hidden toggles and hop caps per plan.
  • CLI overrides accept plan, currency, passengers, proxy, concurrency, debug.

YAML sample

schema_version: v2
defaults:
  currency: USD
  passengers: 1
  request:
    delay: 0.5
    retries: 1
    max_leg_results: 3
  filters:
    max_stops: 1
    include_hidden: true
    max_hidden_hops: 1
  output:
    directory: output
    filename_pattern: "{plan}_{timestamp}.csv"
plans:
  - name: sample-hop
    places:
      home: [ICN]
      city: [FUK, HKG]
    path: [home, city, home]
    departures:
      "home->city":
        dates: ["2026-01-01", "2026-01-02"]
        max_stops: 0
      "city->home":
        window:
          start: "2026-01-04"
          end: "2026-01-05"
    filters:
      "home->city":
        max_stops: 0
    options:
      include_hidden: true
      max_hidden_hops: 1
http_proxy: null
concurrency: 1

Each plan expands airport combinations and departure calendars automatically.

Output fields

  • plan_name marks the source plan for grouping.
  • journey_id stores a stable slug per journey.
  • journey_label summarizes path and chosen dates.
  • variant denotes scheduled legs or hidden discoveries.
  • leg_sequence tracks zero-based leg ordering.
  • origin_place and destination_place map to place identifiers.
  • origin_code and destination_code store airport selections.
  • hidden_via_places and hidden_via_codes capture intermediary hops.
  • departure_date, departure_time, departure_at hold normalized timestamps.
  • duration_hours stores decimal leg durations.
  • airline holds the carrier label.
  • stops and stop_notes capture layover counts and codes.
  • price stores integer fare digits.
  • is_best mirrors Google Flights highlights.
  • currency shows the fare currency code.

Excel itinerary workbook

  • Each run emits <csv_stem>_itineraries.xlsx alongside the CSV export.
  • Columns follow <origin_place>-><destination_place>_<field> naming (e.g., home->las_price).
  • Per-leg fields cover price, currency, departure timestamps, airline, stops, stop_notes, duration_hours, and variant flags.
  • Totals include total_price, total_currency, and aggregated total_duration_hours when data is complete.
  • For practicality the workbook samples the first 10 flights per leg before computing every combination.

Project layout

  • awesome_cheap_flights/cli.py handles CLI parsing and config loading.
  • awesome_cheap_flights/main.py enables python -m execution.
  • awesome_cheap_flights/pipeline.py runs scraping, expansion, and CSV export.

Release automation

  • Pushing main triggers release workflow when relevant files change.
  • Append [minor] to bump the minor version automatically.
  • Use workflow_dispatch for manual bumps when needed.
  • Provide a PYPI_TOKEN secret with publish permissions.
  • Select current to reuse the existing version during manual runs.

Last commit id: 63ccbe0b806376b562debd98600dfef51f1b9a07

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

awesome_cheap_flights-1.0.1.tar.gz (25.5 kB view details)

Uploaded Source

Built Distribution

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

awesome_cheap_flights-1.0.1-py3-none-any.whl (22.8 kB view details)

Uploaded Python 3

File details

Details for the file awesome_cheap_flights-1.0.1.tar.gz.

File metadata

  • Download URL: awesome_cheap_flights-1.0.1.tar.gz
  • Upload date:
  • Size: 25.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.12.3

File hashes

Hashes for awesome_cheap_flights-1.0.1.tar.gz
Algorithm Hash digest
SHA256 e8334fd2ec809d25eb1efbbf96998b0d6ac6bce3909342875c8cf1fbdcc71768
MD5 094f09b7ef1dfcc2ba84d505f98311a9
BLAKE2b-256 040e5e2d60c1c11edf06c20f8f0159bdbd9004bda590432aae8a691353e21dbe

See more details on using hashes here.

File details

Details for the file awesome_cheap_flights-1.0.1-py3-none-any.whl.

File metadata

File hashes

Hashes for awesome_cheap_flights-1.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 745ca06907e797f83829a13db8fba2759fd5e11dd32260dc56a0af1408c45b65
MD5 15cfbd5ea9fc815092c17cbb7ccdfcea
BLAKE2b-256 8e3749f003dd380038148b840b1776b737ad58782f9ce98639f348354b9c536b

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