Skip to content

Fix STR (Stratford-on-Avon) scraper#418

Open
symroe wants to merge 1 commit into
masterfrom
fix/STR-scraper
Open

Fix STR (Stratford-on-Avon) scraper#418
symroe wants to merge 1 commit into
masterfrom
fix/STR-scraper

Conversation

@symroe

@symroe symroe commented Jul 3, 2026

Copy link
Copy Markdown
Member

What broke

democracy.stratford.gov.uk times out from Lambda with wreq's Firefox133 TLS fingerprint. The WAF drops the TLS handshake before sending any response. The endpoint is working correctly from non-Lambda IPs (confirmed 302 via proxy). Same WAF fingerprint block pattern as HAL, TON, MON, GED, COV, and other recently fixed ModGov instances.

What was fixed

  • Added http_lib = "playwright" to the Scraper class — headless Chromium's Chrome TLS fingerprint bypasses the WAF, allowing the ModGov XML endpoint to be reached.

Scrape results

Metric Count
Councillors found TBC (Lambda run needed — endpoint confirmed live from non-Lambda IP)
With email address TBC
With photo TBC

Generated by Claude Code

democracy.stratford.gov.uk times out from Lambda with wreq's Firefox133
TLS fingerprint — the WAF drops the connection. The endpoint is reachable
from non-Lambda IPs (confirmed 302 via proxy). Playwright's Chrome TLS
fingerprint bypasses the WAF, consistent with HAL, TON, MON, GED, COV,
and other recently fixed ModGov instances.
@symroe

symroe commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

Re-scrape after 416f1fc

Added http_lib = "playwright". The STR endpoint blocks our proxy environment's TLS fingerprint, so counts cannot be confirmed here — Playwright in Lambda is needed.

Metric Count
Councillors found TBC (Lambda run needed — endpoint confirmed reachable via proxy 302, server is up)
With email address TBC
With photo TBC

Generated by Claude Code

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant