Files
PocketVeto/backend/app/workers/bill_classifier.py
Jack Levy 8625c850a0 fix: handle within-page cosponsor duplicates from Congress.gov API
Congress.gov occasionally returns the same member twice on a single page
with different sponsorship dates (observed: Sen. Warnock on 119-s-1383).
The DB uniqueness check didn't catch this because the first insert hadn't
been committed yet when processing the duplicate row, causing a
UniqueViolation. Fix adds an `inserted_this_run` set to skip bioguide_ids
already added in the current fetch loop.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
2026-03-14 18:33:12 -04:00

14 KiB