docs: teach table checks (#347) - #351
Merged
Merged
Conversation
Document __ferro_checks__ declaration, CheckViolationError, auto-migrate capability matrix rows, and I-1 ck_<table>_<suffix> naming for table checks. Co-authored-by: Cursor <cursoragent@cursor.com>
Match the migrations matrix (ADR contract, not the Transfer-only slice) and name the column-check FFI that actually exists. Co-authored-by: Cursor <cursoragent@cursor.com>
Contributor
Author
Gate: clearRead the full docs diff. AC for #347 is met.
Nits fixed on the PR: dialect paragraph now states the locked ADR-0016 contract (same as the migrate matrix documenting the ladder before sibling slices land); I-1 column-check FFI named Merging into |
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
Check(suffix, predicate)in__ferro_checks__, lambda style (I-8), live nameck_<table>_<suffix>, andCheckViolationErroron violation — with Assignment/Annotated tabs sharing the same ClassVar (I-7).db_checkreconcile rows (add / rebuild / drop / leftover warning; SQLite create-inline vs reconcile skip per ADR-0013/0014).ck_<table>_<suffix>table-check naming alongside column checks.docs/examples/table_checks.py+_annotated.pycompanions; noteCheckViolationErroron the exceptions API page.Test plan
uv run pytest tests/test_docs_examples.pyIssue closure
Closes #347
featPRD: table-level CHECK constraints (multi-column), auto-migrated #339)Made with Cursor