Skip to content

docs(aggregation): Place docstring before class attributes - #819

Merged
ValerianRey merged 3 commits into
SimplexLab:mainfrom
SausageMan99:fix/807-cagrad-weighting-docstring
Oct 7, 2026
Merged

ValerianRey merged 3 commits into
SimplexLab:mainfrom
SausageMan99:fix/807-cagrad-weighting-docstring

Conversation

@SausageMan99

Copy link
Copy Markdown
Contributor

Fixes #807.

_REQUIRED_DEPS and _INSTALL_HINT were defined before the docstring, so CAGradWeighting.__doc__ was None and its doc entry was empty. The attributes are now placed after the docstring (same layout as QuadprogProjector).

I scanned src/ for the same pattern and found it in one other place, the private _NashMTLWeighting, which I fixed too.

Added a regression test and checked that make html -C docs builds and that the CAGrad page now shows the docstring.

This change was prepared with the help of an AI agent (Claude) and reviewed by me before opening.

…utes

_REQUIRED_DEPS and _INSTALL_HINT were defined before the docstring, so the
string literal was not the class docstring and CAGradWeighting.__doc__ was
None, leaving its documentation entry empty. The same issue affected the
private _NashMTLWeighting.

Fixes SimplexLab#807

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Comment thread tests/unit/aggregation/test_cagrad.py Outdated

@ValerianRey ValerianRey left a comment

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM

@ValerianRey ValerianRey added cc: docs Conventional commit type for changes to the documentation. package: aggregation labels Oct 7, 2026
@ValerianRey
ValerianRey enabled auto-merge (squash) October 7, 2026 16:30
@ValerianRey ValerianRey changed the title fix(aggregation): Place CAGradWeighting docstring before class attributes fix(aggregation): Place docstring before class attributes Oct 7, 2026
@github-actions github-actions Bot changed the title fix(aggregation): Place docstring before class attributes docs(aggregation): Place docstring before class attributes Oct 7, 2026
@ValerianRey
ValerianRey merged commit b98cc51 into SimplexLab:main Oct 7, 2026
18 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cc: docs Conventional commit type for changes to the documentation. package: aggregation

Projects

None yet

Development

Successfully merging this pull request may close these issues.

CAGradWeighting has no docstring, so its doc page is empty

2 participants