Skip to content

docs(v1): describe join=None default without headlining "exact"#832

Merged
FBumann merged 1 commit into
feat/arithmetic-conventionfrom
docs/join-default-semantics
Jul 15, 2026
Merged

docs(v1): describe join=None default without headlining "exact"#832
FBumann merged 1 commit into
feat/arithmetic-conventionfrom
docs/join-default-semantics

Conversation

@FBumann

@FBumann FBumann commented Jul 15, 2026

Copy link
Copy Markdown
Collaborator

Stacked on #717. Docs-only: clarifies what the join=None default means so users can reason about alignment without reading the source.

Note

The following was generated by AI.

The public join docstrings (Variable / LinearExpression .add/.sub/.mul/.div/.le/.ge/.eq, plus the internal _align_constant helper) previously said either the vague "current default behavior" (variables.py) or headlined "exact" under v1 (expressions.py). The two files had drifted, and "exact" overstates it: under v1 on #717 a pure reorder does not raise — it aligns by label; only a differing label set raises.

Every public docstring now reads consistently:

When None (default), follows the semantics setting: under v1, shared dimensions must carry the same label set — a pure reorder aligns by label, a differing set raises; under legacy, positional alignment.

No behavior change. When the exact-alignment work (#831) tightens §8, this wording flips in one place: "a pure reorder aligns by label" → "raises".

The default join follows options["semantics"]. Describe v1 directly —
shared dims must carry the same label set, a pure reorder aligns by
label, a differing set raises — rather than calling it "exact", which
overstates it (v1 is order-independent; a reorder does not raise on
#717, only a differing label set does). Applied to both the Variable and
expression methods so their docstrings stay in parity.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
@FBumann
FBumann merged commit 28de967 into feat/arithmetic-convention Jul 15, 2026
1 of 2 checks passed
@FBumann
FBumann deleted the docs/join-default-semantics branch July 15, 2026 14:59
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant