From fdcf4c88c03f9aff4999ea3df89f949bbf4ade3e Mon Sep 17 00:00:00 2001 From: Claude Date: Thu, 30 Jul 2026 23:03:12 -0700 Subject: [PATCH] Add lexicon for catalog snapshot records A catalogSnapshot record is one immutable snapshot of the Racket package catalog. Record keys are TIDs, so multiple snapshots in a day are allowed. publishedAt and createdAt are separate: publishedAt is when the upstream snapshot finished building, so consumers see when it really appeared rather than when we happened to poll for it. Both are UTC with a Z suffix. Co-Authored-By: Claude Fable 5 --- ....notjack.thunderstorm.catalogSnapshot.json | 36 +++++++++++++++++++ 1 file changed, 36 insertions(+) create mode 100644 lexicons/space.notjack.thunderstorm.catalogSnapshot.json diff --git a/lexicons/space.notjack.thunderstorm.catalogSnapshot.json b/lexicons/space.notjack.thunderstorm.catalogSnapshot.json new file mode 100644 index 0000000..e30f0cb --- /dev/null +++ b/lexicons/space.notjack.thunderstorm.catalogSnapshot.json @@ -0,0 +1,36 @@ +{ + "lexicon": 1, + "id": "space.notjack.thunderstorm.catalogSnapshot", + "defs": { + "main": { + "type": "record", + "description": "An immutable snapshot of the Racket package catalog at one moment in time. Snapshots are currently always Racksnaps daily builds. Record keys are TIDs rather than a date-derived slug, so nothing here assumes at most one snapshot per day.", + "key": "tid", + "record": { + "type": "object", + "required": ["url", "publishedAt", "createdAt"], + "properties": { + "url": { + "type": "string", + "format": "uri", + "description": "Catalog root URL for this snapshot: the directory containing pkg/, pkgs, and pkgs-all. This identifies the snapshot, being unique per snapshot and, for Racksnaps, containing the build date." + }, + "packageCount": { + "type": "integer", + "description": "Packages listed in the upstream catalog, which may exceed the number Thunderstorm has ingested. Optional because whatever creates this record need not have fetched the package list." + }, + "publishedAt": { + "type": "string", + "format": "datetime", + "description": "When the upstream catalog finished building this snapshot. Distinct from createdAt so that a consumer sees when the snapshot really appeared rather than when Thunderstorm happened to poll for it. Must be UTC, written with a 'Z' suffix rather than a numeric offset." + }, + "createdAt": { + "type": "string", + "format": "datetime", + "description": "When Thunderstorm created this record. Must be UTC, written with a 'Z' suffix rather than a numeric offset." + } + } + } + } + } +} -- 2.51.2