BUG: numpy needs to override the sphinx autosummary class.rst
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 355
- Forks
- 181
- Avg merge
- 1d 9h
- Merged PRs (30d)
- 3
Description
I am not sure of the interactions between all the pieces, but here my understanding:
- numpy has a
class.rsttemplate that extends the one in sphinx's autosummary extension. It adds atoctreeoption to a nestedautosummarydirective (nested under aHACKdirective) - During the parse phase, sphinx adds the
toctreecontents to the documentation, since this is all done with regex and it doesn't care there are nested directives - Since sphinx ignores nested directives during output processing, the
toctreeis not generated - As far as sphinx is concerned, the generated documents are not in any
toctree, so we added anorphantag to them in additional templates in numpy to avoid a warning.
So why do we need the toctree in the template in the first place? Removing the numpy class.rst seems to produce problematic documentation. Is this a numpydoc or sphinx problem or just a feature?
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by inspecting numpydoc's numpy class.rst template and the corresponding Sphinx autosummary template, then reproduce the documentation build described in the issue. Trace how the nested autosummary, toctree, and orphan directives are handled. Done means determining whether this belongs in numpydoc or Sphinx and documenting or implementing the agreed fix.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- documentation
- Issue type
- Bug
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 20/100