Repository navigation
Releases
v1.1.0
Behaviour changes. Exit codes: a run whose content was never obtained —
no answer from the site over plain HTTP, an empty document from a browser
navigation, a page that lists products but parsed to none — now exits 5
(it was 3, or 4). A transport fault AFTER some pages gave rows now writes
those rows and exits 6 (the browser engines used to discard them and
exit 5). A URL that is not a homedepot.com host, or no URL at all, now exits
2 (it was 1). Output files now take their mode from the umask, or keep
an existing file's mode, instead of always being 0600. CSV cells that a
spreadsheet would execute now start with'. The canary now FAILS when no
exit secret is set, instead of skipping green.
Fixed
- The paid captcha rung could not run.
browser_bridgecalled a solver
function that does not exist and swallowed the error, so a detected
reCAPTCHA was never solved. It now reconciles the page's static and live
detections, buys at most ONE solve per page (an allowance checked before
the purchase and never reset), and buys only what it can use: the engine
must be able to inject the token, and reCAPTCHA Enterprise — not
implemented here — is never paid for. No widget has been seen on this site;
this is the path for when one appears. http_scraper.pyreported a dead connection or proxy as blocked (exit
3). It now reports exit 5, or 6 after earlier rows. A refused proxy
credential on page N keeps the rows from pages before it.http_scraper.pyasked a refusing exit the same question again when
there was no other exit to move to. A 403 or the interstitial without a
pool now ends that page after one request.- The browser engines lost rows on a transport fault after page 1, and
wrote no.latest_attempt.meta.json. Both are written now. An unexpected
exception in our own code is a crash (exit 1), not a "remote error". - An empty document (a navigation that produced nothing) has its own
message and exit 5, instead of reading as Akamai's refusal. - A served listing that parses to zero rows is reported as a parser
failure (stop_reason: parser_found_nothing), not as an empty category. finish_runmapped any unknown reason with zero rows to "empty
catalogue". Only a complete run, a hub or an empty listing is exit 4 now.- A typed
--category-urllost toHOMEDEPOT_URLin.env. What you
type wins. - Outputs were always 0600. New files follow the umask; an existing file
keeps its mode. - CSV formula cells. Strings beginning
=,+,-,@, tab, CR or LF
get a leading apostrophe in the CSV only, after list cells are joined;
numbers and the JSON are untouched. The sidecar records
csv_cells_escaped. scraper_api_client.pycrashed on the API's response: it read the
target status fromstatus, which is the API's verdict string. It now
readshttp_code, masks thex-debugheader before logging it, keeps
earlier rows when a later call fails, and validates--pages,--delay
and--timeout.diff_runs.pytracked columns this repo does not have and missed
store_quantityandlocal_delivery_quantity. It now tracks this repo's
own columns and refuses to compare runs that priced different stores; every
run records itsscope.store_id.- The secret scan read tracked files only. It now also reads untracked
files that are not ignored, skips virtualenvs by theirpyvenv.cfg, and
says how many files it read. --dump-htmlfiles were not ignored (x_p1.html); they are now.- The README listed
--fingerprintfor two browser engines that have no
such flag. The row is gone. - Contributor docs, issue templates, ignore files,
page_flow.pyand
output_writer.pydescribed another site's catalogue; they describe Home
Depot's now. Unused policy helpers inpage_flow.pywere removed.
Changed
- The canary runs the engine that can work from a runner, and fails when it
cannot. WithHOMEDEPOT_PROXYit runshttp_scraper.py; with
HOMEDEPOT_CDP_ENDPOINT, Playwright over CDP; with neither, it fails and
names both. Exit 3, 4, 5 or 6 fails it, and the row floor, core fields and
pagination are asserted byci_checks.py --run-check.
v1.0.0
Home Depot category and product scraper — prices, stock, brand, model, ratings and the site's own category hierarchy, to JSON or CSV with a run-metadata sidecar.
Four transports over one parser and one row schema: plain HTTP (via curl), Playwright, Selenium, pyppeteer, and a remote browser over CDP.
See README.md and CHANGELOG.md.