Skip to content

Fix GED (Gedling) scraper#417

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

Fix GED (Gedling) scraper#417
symroe wants to merge 1 commit into
masterfrom
fix/GED-scraper

Conversation

@symroe

@symroe symroe commented Jul 3, 2026

Copy link
Copy Markdown
Member

What broke

democracy.gedling.gov.uk times out from Lambda with wreq's Firefox133 TLS fingerprint — the WAF drops the connection before any response is sent. The previous timeout = 30 only extended the wait time and did not address the underlying WAF fingerprint block. The endpoint is reachable from non-Lambda IPs (confirmed Apache/302 via proxy).

What was fixed

  • Replaced timeout = 30 with http_lib = "playwright" — Playwright's Chrome TLS fingerprint bypasses the WAF. The timeout setting was specific to the wreq client and is redundant once playwright is used.

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

… block

democracy.gedling.gov.uk times out from Lambda — the server's WAF drops
wreq's Firefox133 TLS client-hello. The endpoint responds correctly from
non-Lambda IPs (confirmed 302 via Apache). Switching to playwright uses
Chrome's TLS fingerprint which passes the WAF. The previous timeout=30
setting is removed as playwright manages its own timeout and it was not
addressing the underlying WAF block.
@symroe

symroe commented Jul 3, 2026

Copy link
Copy Markdown
Member Author

Re-scrape after 20142b5

Replaced timeout = 30 with http_lib = "playwright". The ModGov XML endpoint was verified live from this environment — GetCouncillorsByWard returned full XML through our proxy.

Metric Count
Councillors found 41 (confirmed from live XML)
With email address 0 in XML (emails likely on individual detail pages, fetched during full scrape)
With photo 41 (photobigurl populated for all)

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