Skip to content

Fix OLRC fetcher for 2026 site redesign; correct vintage dates; add 119-142 - #46

Open
nickvido wants to merge 2 commits into
mainfrom
fix/olrc-site-redesign
Open

nickvido wants to merge 2 commits into
mainfrom
fix/olrc-site-redesign

Conversation

@nickvido

Copy link
Copy Markdown
Owner

Problem

  • fetch --source=olrc (and --list-vintages) fails with OLRC listing did not expose any releasepoint title ZIP links. OLRC redesigned uscode.house.gov: /download/download.shtml and /download/priorreleasepoints.htm now return 404. The new pages are /download.html and /priorreleasepoints.html. The ZIP URL scheme (/download/releasepoints/us/pl/{congress}/{law}/xml_usc{NN}@{vintage}.zip) is unchanged.
  • DOWNLOAD_TIMEOUT_MS was 500 ms, so the first attempt was regularly aborted before the server responded.
  • Most KNOWN_VINTAGES release dates were wrong. 119-73 is January 23, 2026, not 2025-03-14, so it was tagged annual/2025 when it belongs in 2026.
  • There's a new release point: PL 119-142 (November 10, 2026).

Changes

  • Discovery points at https://uscode.house.gov/download.html. Test mocks are updated to the new URL.
  • The OLRC request timeout goes from 500 ms to 30 s.
  • Every KNOWN_VINTAGES date is corrected to the date OLRC lists. Pre-119 dates come from the archived priorreleasepoints.htm. No year changes except 119-73's.
  • 119-142 is added to KNOWN_VINTAGES, seed-all-vintages.sh and run-backfill.sh. It takes the annual/2026 tag.
  • run-backfill.sh takes its heap size from BACKFILL_HEAP_MB, default 6 GB.
  • Backfill now logs titles that fail to parse; it used to skip them silently.

Note: historical release points are no longer on OLRC

OLRC now hosts only 119th-Congress release points. 113-xx through 118-xx return 404, both the ZIPs and their pages. To rebuild the corpus, the xml_uscAll@<vintage>.zip archives for those vintages were taken from the Wayback Machine (web.archive.org/web/<ts>id_/…). Each passed unzip -t, and each was split into the per-title cache layout.

Tests

The planner tests are updated for the corrected year. The full suite has the same 17 failures as main in this environment (zip isn't installed) and no new ones.

🤖 Generated with Claude Code

nickvido and others added 2 commits November 20, 2026 23:46
…19-142

- OLRC moved its download listing from /download/download.shtml to
  /download.html. Point discovery at the new page (the old one 404s, which
  made `fetch --source=olrc` and `--list-vintages` fail).
- Raise the OLRC request timeout from 500ms to 30s; the first attempt was
  routinely aborted before the server responded.
- Correct every KNOWN_VINTAGES release date to the date OLRC lists for the
  release point. 119-73 is January 23, 2026 (was 2025-03-14 / annual/2025),
  so it now falls in 2026.
- Add release point 119-142 (November 10, 2026), which takes annual/2026.
- Log titles that fail to parse during backfill instead of skipping silently.

OLRC now hosts only 119th-Congress release points; older ZIPs must come from
an archive such as the Wayback Machine.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
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