feat(ci): ai admission fixture corpus for publish-time parity (#627) - #629
Merged
Merged
Conversation
103 registry-owned accept/reject fixtures for the spec 001 FR-017 / spec 026 ai rules with a test that drives the exact CI code paths. traverse-cli capability publish vendors a pinned copy (traverse Decision 109). Also fixes four TypeError crashes on non-string rights/status/transformation/kind values. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This was referenced Oct 2, 2026
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 join this conversation on GitHub.
Already have an account?
Sign in to comment
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.
Summary
Closes #627. Adds a registry-owned fixture corpus for the
aiadmission rules: accept/reject cases plus a test provingcapability_validation.pyagrees with every one.traverse-cli capability publishwill vendor a pinned copy, so it can reject the same contracts locally before a registry PR exists (traverse Decision 109, traverse-framework/traverse#1459 / traverse-framework/traverse#1597).Governing Spec
Project Item
What Changed
scripts/ci/fixtures/ai_admission_corpus.json: 103 fixtures,corpus_version1.0.0.tier(contract_decidable|ci_only), anevaluated_as(newly_added|existing), and the sorted set of expected CI error codes.ai: null, and mixed arrays;rights_change;ci_onlycases.scripts/ci/tests/test_ai_admission_corpus.pyruns the exact CI code paths. It is wired into the required capability-validation job.validate_ai_declarationis split out ofvalidate_contract, with no behaviour change. The existing 210 tests pass unchanged.TypeError: unhashable typecrashes. A list or object given as a rights enum,verification.status, aderivation.transformations[]entry, ordata_obligations[].kindcrashed CI instead of failing with the documented code. All four are now guarded and covered by fixtures.docs/model-rights.md: a new "Admission fixture corpus" section, with the rule that changing anairule means updating the fixtures in the same PR.Validation
python3 -m unittest scripts/ci/tests/test_ai_admission_corpus.py: all 103 fixtures agreepython3 -m unittest scripts/ci/tests/test_capability_validation.py: 210 tests passTypeErroronmain's validator and fail cleanly with this changepre_pr_check.sh🤖 Generated with Claude Code