Skip to content

Add catalog refresh to self-update monthly torrent hashes#8

Merged
tamnd merged 1 commit into
mainfrom
catalog-auto-refresh
Jul 19, 2026
Merged

Add catalog refresh to self-update monthly torrent hashes#8
tamnd merged 1 commit into
mainfrom
catalog-auto-refresh

Conversation

@tamnd

@tamnd tamnd commented Jul 19, 2026

Copy link
Copy Markdown
Owner

The monthly dump hashes lived in a compiled-in map, so every new month meant a code edit plus a rebuild. This adds arctic catalog refresh so the CLI keeps itself current.

  • Fetches the arctic_shift GitHub releases, extracts each month's comment/submission dump hash from its Academic Torrents link (or magnet btih), and caches new months to catalog-monthly.json under the data dir.
  • Startup layers that cache over the built-in map, so a long-running binary resolves months published after it was built, no rebuild needed.
  • The parser only accepts a release that names a month, carries a 40-hex hash, and references that month's RC_/RS_ dump files, so subreddit-metadata and tooling releases are skipped.
  • --dry-run reports new months without writing the cache.

Verified against the live releases: every current month resolves as already known through 2026-06 (the newest published, Jul 12), and every fetched hash matches the compiled catalog exactly. Full suite + vet green.

The monthly dump hashes were a compiled-in map, so each new month needed a code
edit and rebuild. Add `arctic catalog refresh`: it fetches the arctic_shift
GitHub releases, pulls each month's comment/submission dump hash from the
Academic Torrents link (or magnet), and caches new months to
catalog-monthly.json under the data dir. Startup layers that cache over the
built-in map, so a running binary resolves dumps published after it was built.

The parser only accepts a release that names a month, carries a 40-hex hash, and
references that month's RC_/RS_ files, so subreddit-metadata and tooling
releases are ignored. A refresh against the live releases reports every current
month as already known through 2026-06.
@tamnd
tamnd merged commit 01cb3ea into main Jul 19, 2026
6 of 7 checks passed
@tamnd
tamnd deleted the catalog-auto-refresh branch July 19, 2026 16:07
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