feat(catalog): admit the per-kind entries/<kind>/<slug>/ shelf layout - #472
Merged
Conversation
Prereq for genwave-catalog#33 (entries split into per-kind folders): the index validator now accepts BOTH the flat entries/<slug>/ layout the live origin serves today and the nested entries/<kind-plural>/<slug>/ layout it will serve after the move. The kind folder, when present, must name the entry's own kind; the slug-ownership check reads the second-to-last path segment (valid in both layouts); and a new one-directory invariant pins an entry's manifest/meta/assets to a single directory — which is what keeps bare filenames unique for the filename-keyed asset route now that the same slug could otherwise appear under two layouts at once.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
🎯 What
Prereq for GenWave-Org/genwave-catalog#33 (split
entries/into per-kind subfolders).CatalogIndexValidatornow admits both shelf layouts:entries/<slug>/…— what the live origin serves todayentries/<kind-plural>/<slug>/…— what it serves after the move (personas/,themes/,fonts/,shows/)🔒 How it stays strict
entries/shows/fails its pattern outright.Split('/')[1].entries/fonts/x/OFL.txtandentries/x/OFL.txtcoexist in one entry — distinct paths, same bare filename, and the asset route looks files up by bare filename.🧪 Tests
🚦 Sequencing
This must be released and deployed before the catalog-side migration PR merges — an old station fetching a migrated index rejects the whole index (fail-closed), so the shelf would go empty until upgraded. Broadcast is unaffected either way.