Repository navigation
feat(id-caps): library manifest platform-block parser + catalog validator (#10027 §7 step 1) - #10135
Conversation
Codex Review Summary: ❌ FailedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Warning Review limit reachedYou've used all free OSS reviews for now. Wait for the free limit to reset to keep reviewing this public repository. Next included review available in 23 minutes. View limit details
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. |
|
You have reached your Codex usage limits for code reviews. You can see your limits in the Codex usage dashboard. |
Implements §7 step 1 of the merged #5956 design record (PR #10023) for #10027: the library manifest
platform-block parser + validator against theid-capscatalog.What lands
pkgs/id/crates/id-caps/src/library_manifest.rs:key=valueproperties, nested blocks,//comments, newline/;terminators — and fails closed outside it).LibraryManifest::parsevalidates fail-closed, mirroringWorldManifest::parse: required fields (name, version, kind, build-mode, hash, license — id: design: library typing & upload taxonomy — subtypes, entity attachment, DLL vs compile-in, libraries by URL #5969 §2: a manifest without a content hash is not a library), kind/build-mode agreement (id: design: library typing & upload taxonomy — subtypes, entity attachment, DLL vs compile-in, libraries by URL #5969 §5), url-library source requirement (id: design: library typing & upload taxonomy — subtypes, entity attachment, DLL vs compile-in, libraries by URL #5969 §6).requiresnames an exact catalog entry inPRODUCTION_CATALOG_ENTRIES(unknown names fail closed), no wildcards, no duplicates, and an optionalversion=pin must equal the compiling catalog's version, with the mismatch named.platformblock is the pure case: the empty requirement set, never a self-asserted label (id: design: pure-package import policy — package classes per tier, with compile-fail fixtures #5994 §5.5).subtype/attach/sourcenodes are carried structurally for the registry consumers that follow.Recorded scope note
§7 step 1 says "wired into the registry/upload path #5969 defines" — that path is a design record only; no registry/upload code for libraries exists in the tree yet. This PR therefore lands the parser+validator as the
id-capsseam that path will call, and says so in the module docs. Steps 2–5 of §7 (transitive resolver, compile-path import gate, #5994 fixture matrix, citation updates) remain on #10027 as the follow-on queue task enqueued at this slice's close-out.Tests
10 new unit tests in the module, each naming its oracle (the invariant or diagnostic it pins): design-example parse, absent-platform purity, unknown-requirement fail-closed, wildcard refusal, duplicate refusal, version-pin mismatch naming both versions, missing-hash refusal, kind/build-mode disagreement, unknown-node fail-closed, url-library source requirement.
cargo test -p id-caps— see the close-out note on #10027 for the run result.Queue task 16915 (lane any-c).
Open in [code]smith · Need help on this PR? Tag
@codesmith-botwith what you need.