docs(language): the rules binding obeys belong to the language, not to whichever engine reads the data - #242
Merged
Conversation
Documentation build overview
40 files changed ·
|
FBumann
marked this pull request as draft
August 29, 2026 14:17
This was referenced Aug 29, 2026
FBumann
force-pushed
the
claude/data-rules-in-the-language
branch
from
August 30, 2026 18:19
a0cc2d4 to
1e2b8a9
Compare
This was referenced Aug 30, 2026
FBumann
force-pushed
the
claude/data-rules-in-the-language
branch
from
August 31, 2026 18:29
1e2b8a9 to
33b7db7
Compare
FBumann
marked this pull request as ready for review
August 31, 2026 20:46
…o whichever engine reads the data Three facts decide which model a file and a table make together — where a dimension's members come from, the order they stand in, and that a coordinate appears at most once. Each was real and each was written down in a consumer, so a second consumer would have inherited none of them. Co-Authored-By: Claude <noreply@anthropic.com> (cherry picked from commit 1e2b8a9)
FBumann
force-pushed
the
claude/data-rules-in-the-language
branch
from
September 2, 2026 08:28
33b7db7 to
f488380
Compare
FBumann
added a commit
that referenced
this pull request
Sep 2, 2026
…rce (#378) The rule as merged in #242 said a dimension nothing supplies is an error, with no qualifier. A declared dimension no declaration reaches builds and solves in lpspec today, so the rule was stricter than any implementation of it. Claude-Session: https://claude.ai/code/session_013a3tFCULeY7Skmkhbxpj7V Co-authored-by: Claude Opus 5 (1M context) <noreply@anthropic.com>
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.
Note
The following content was generated by AI.
What this changes
Three facts decide which model a file and a table make together. Each is real, each is load-bearing, and each was written down in a consumer rather than in the language — so a second consumer would inherit none of them.
lpspec/sources.py::check_index_ownershipunique(maintain_order=True)lpspec/sources.py, as "by contract"Docs only, 2 files, +38/-3.
Why
what-counts-as-language.mdalready decides it: "A consumer may not state a rule about the language that another consumer then has to restate."The order rule is the one with teeth.
shift,sum_backandposition()all walk it, so a Julia consumer reading only the language reference could reasonably sort — and answershift(p, over=snapshot, offset=1)with a different row, silently, with no error anywhere. #32 notes "nothing in a file says they arrive sorted"; this says what does.What lpspec removes or changes
Nothing behavioural.
unique(maintain_order=True)already is the rule. What changes is who speaks:check_index_ownership,_labels/polars_indexand the"by contract"comment stop stating rules and start implementing ones the language states. Can land any time after this — nothing breaks while both say the same thing.Verified
pixi is unavailable here, so the toolchain was reconstructed at the versions
pixi.tomlpins and run directly on this branch:ruff format --checkandruff check(0.16.1, the pinned version) clean;pyrefly(1.2.0, pinned) 0 errors;reuse lintcompliant 196/196;typosclean;prettier --checkclean;pytest -q -n auto829 passed, 1 skipped;mkdocs build --strictbuilds.The strict docs build is the gate that matters for a docs PR. It aborts locally on
Couldn't load inventory https://docs.python.org/3/objects.inv … 403 Forbidden— the sandbox proxy refusing an outbound fetch, not a content error — so I dropped that one config line for a local run and restored it (mkdocs.ymlis unchanged in the diff). Read the Docs then built the PR for real, inventory fetch included, which is the stronger evidence.Not run:
zizmor(no workflow changed),taplo(no TOML changed),compile-tex(no model file changed).Deliberately not done
Not made an eleventh rule. These arguably belong in the ten-rule table in
reference/language/index.md. Renumbering "the ten rules" is an editorial decision about the front door and it is yours — two lines if you want it.No enforcement here, because there is nothing to enforce without data. Message constructors not moved: the sentences these rules print still live in
lpspec/sources.py, and moving them needs anerrors.pyaddition here first.Stack: base of three, on #168 — which is behind
main(based on #211,mainat alpha.47), so the stack rebases when that lands.Closes #295