checkpoint finder

This commit is contained in:
Andras Schmelczer 2026-03-24 22:30:37 +00:00
parent 8616837c01
commit 96dfdd7491
5 changed files with 130 additions and 20 deletions

View file

@ -351,7 +351,7 @@ def parse_search_results(html: str) -> list[dict]:
<div class="fw-medium text-primary fs-3">1 Bed Flat, Location, SW1Y</div>
<ul>...<li>1 Bed</li><li>1 Bath</li><li>Furnished</li>...</ul>
"""
soup = BeautifulSoup(html, "html.parser")
soup = BeautifulSoup(html, "lxml")
properties = []
# Property cards: <a class="pli search-property-card">
@ -486,7 +486,7 @@ def parse_property_detail(html: str) -> dict:
- Tables have "Rent PCM", "Deposit", "Bills Included", etc. (NOT bedrooms)
- Description in elements with class containing "description"
"""
soup = BeautifulSoup(html, "html.parser")
soup = BeautifulSoup(html, "lxml")
details: dict = {}
# --- Title from h1 ---
@ -810,7 +810,7 @@ def search_outcode(
if detail_html:
detail_data = parse_property_detail(detail_html)
# Shorter delay for detail pages (within same outcode)
time.sleep(DELAY_BETWEEN_PAGES * 0.5)
time.sleep(0.15)
transformed = transform_property(
search_data,