Model/infrastructure/epc_client
Khalim Conn-Kowlessar efaff228ac feat(scripts): add --from-db re-model path + raise EPC API timeout
- run_modelling_e2e --from-db re-models from already-persisted inputs (reads
  each Property's Effective EPC + planning protections + solar from the DB) and
  skips every live fetcher — zero gov-API calls. With --persist it re-writes the
  Plan and, for lodged-EPC Properties, the Baseline. Self-contained loop; the
  live-fetch path is untouched. Makes local re-runs instant and avoids tripping
  the gov API's per-IP rate limit (6000 req / 5 min) during iteration.
- EpcClientService.REQUEST_TIMEOUT 10s -> 30s: a cold per-UPRN search can exceed
  10s and the old timeout turned it into a timeout-then-retry; 30s rides it out.

Note: an open perf question remains — modelling is fast in isolation (<0.5s/
property) but a long-lived --persist run shows ~1 min/property; suspected in the
persist path (plan.save / baseline) or connection handling, NOT the API. Left
mid-diagnosis for handover.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
2026-06-23 11:05:06 +00:00
..
__init__.py feat(ingestion): relocate EpcClientService to infrastructure + SolarRepo (#1133) 2026-05-30 19:45:26 +00:00
_retry.py neighbouring properties added 2026-06-22 14:38:00 +00:00
epc_client_service.py feat(scripts): add --from-db re-model path + raise EPC API timeout 2026-06-23 11:05:06 +00:00
exceptions.py feat(ingestion): relocate EpcClientService to infrastructure + SolarRepo (#1133) 2026-05-30 19:45:26 +00:00