Skip to content

v2.16.0 — The Crawler That Refuses to Die

Latest

Choose a tag to compare

@dmae97 dmae97 released this 21 Oct 03:43
· 5 commits to main since this release

The free-proxy rotation chain: harvest from public lists → validate → rotate
per request → feed every outcome back → refill on exhaustion. The engine
v2 and the self-healing freshness layer already existed; this change wires
them into the crawl path, fixes their deployment blockers, and adds the
first tests they ever had.

Fixed

  • proxy_engine_v2: cache path was a hardcoded absolute path from another
    machine (/home/yu/...) — now project-relative .crawl_cache (env
    OMK_CACHE_DIR still wins). IPv6 probe no longer runs on the constructor's
    critical path (lazy, once). Burned proxies are now persisted (in-memory
    burn died on restart and the cache resurrected known-bad endpoints).
  • Protocol detection read the URL scheme, so every https-served text list
    (all of GitHub raw) was labeled https. Detection now uses filename/query
    markers (http.txt, protocol=socks5, type=http, HTTPS_RAW,
    /socks5_list/) with the scheme excluded.
  • aiohttp/aiohttp-socks were lazy-imported but declared nowhere — new
    proxy extra (pip install 'omk-crawl[proxy]'), included in all.

Added

  • Freshness ("newest"): ProxyNode.harvested_at/source; a source
    re-serving a proxy touches its freshness instead of duplicating it;
    STALE_SECONDS (default 1h, OMK_PROXY_STALE_SECONDS) demotes stale
    entries in scoring and next(fresh_only=True) excludes them.
  • rotate_crawl.py — RotationCrawler: one pool proxy per attempt over
    curl_cffi with the node's assigned TLS profile; outcome feedback
    (ok→score up, 429→per-proxy backoff, 407→burn, blocked/error→failure
    streaks); bounded synchronous refill when the pool empties mid-crawl;
    crawl_many() bounded concurrency. pool_cycles() is the bounded
    무한의 굴레 loop (cycles=0 → until cancelled).
  • proxy:// scheme + ProxyPoolTool: proxy://stats (offline),
    proxy://refresh, proxy://loop?cycles=N&interval=S. Bad query params
    fail closed as results, never raise (BaseTool contract).
  • CLI --proxy-pool: crawl a URL through the rotation pool.
  • 30 offline tests (tests/test_proxy_rotation.py); suite now 714 passing.

Verification boundaries

  • Live harvesting/validation against public proxy sources and the Firebase
    validation target are network paths exercised only by the live lane — the
    offline suite covers parsing, scoring, selection, feedback, persistence
    and CLI plumbing with fakes.
  • Same-domain-style caveat: free proxies are untrusted third parties —
    credentials or personal data must not transit them; the pool is for
    public-content crawling only.