docs: indent struct-field descriptions to 4 spaces - #695
Merged
Conversation
The `info` return of sampleCHRR and the `result` return of gapFillTopological listed their fields at 2 spaces of indentation. In numpydoc style a description continuation must be indented 4 spaces relative to the name, so the docs generator reported "Confusing indentation for continuation line" 18 times and the field lists risked rendering outside their entry. Indent the field lines to 4 spaces and give both entries the plain type `struct`, matching compareFluxes.m, which documents a struct return the same way without warnings. Documentation only; no functional change.
Function test results300 tests 274 ✅ 1m 18s ⏱️ Results for commit 19354cc. |
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.
Problem
Building the RAVEN documentation site emits 18 warnings of the form:
Both come from the same pattern — a struct-valued return whose fields are
listed at 2 spaces:
In numpydoc style, a description continuation must be indented 4 spaces
relative to the entry name. At 2 spaces the field list is not reliably read as
part of the entry, so it can render outside it on the generated API page.
Fix
Indent the field lines to 4 spaces, and give both entries the plain type
struct. That matchesanalysis/compareFluxes.m, which documents a structreturn the same way and produces no warnings:
Documentation only — no functional change.
Verification
With these two files in place,
mkdocs build --strictin the docs site reportszero "Confusing indentation" warnings, down from 18.
Found while writing the flux-variability and gap-filling pages of the new
user guide.