ammocpr/lib/ammoprices
Graham McIntire 2efb35dc48
Stop scrape chain from dying on a single bad product
A scraped product with nil price_per_round_cents made Prices.create_snapshot
return {:error, changeset}, which blew up the {:ok, _} match in the runner,
crashed the whole perform, and after 3 retries discarded the job. Nothing
reseeds the chain once the job is discarded, so prod scrapes silently died
on Mar 17 and stayed dead until the app was restarted.

- Runner handles snapshot insert errors by logging and continuing instead
  of raising.
- ScrapeJob wraps each Runner.run in try/rescue so one retailer crashing
  doesn't take down the whole cycle.
- ScrapeJob moves schedule_next into an after block so the chain is always
  reseeded, even if the scrape loop crashes.
2026-04-22 15:51:15 -05:00
..
catalog Add Target Sports USA scraper, product filtering, and subsonic detection 2026-03-11 16:28:04 -05:00
prices Initial implementation of ammo price tracker 2026-03-11 15:58:12 -05:00
scraping Stop scrape chain from dying on a single bad product 2026-04-22 15:51:15 -05:00
application.ex Add credo with --strict mode and fix all issues 2026-03-12 13:35:12 -05:00
catalog.ex Prune listings that disappear from retailer scrapes 2026-04-22 15:41:40 -05:00
mailer.ex Initial implementation of ammo price tracker 2026-03-11 15:58:12 -05:00
prices.ex Add Target Sports USA scraper, product filtering, and subsonic detection 2026-03-11 16:28:04 -05:00
release.ex Add Dokku deployment configuration 2026-03-11 16:51:44 -05:00
repo.ex Initial implementation of ammo price tracker 2026-03-11 15:58:12 -05:00