Skip to content

docs: handle special sections like Metadata in the docstring. #133

@ycexiao

Description

@ycexiao

Problem

In the docstrings, there are sections besides the standard sections used in numpy-style docstrings. For example, in sasparser.py:

    General Metadata
    ----------------
    filename
        The name of the file from which data was parsed. This key
        will not exist if data was not read from a file.
    nbanks
        The number of banks parsed.
    bank
        The chosen bank number.

sphinx-napoleon can't recognize these sections and will cause rendering issues.

Currently, they are all being handled as Attributes, so only the items like filename appear in the rendered documentation, not the headers like General Metadata. Maybe we want to find a way to better handle these special sections?

Proposed solution

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions