sphinx-doc / sphinx

The Sphinx documentation generator
https://www.sphinx-doc.org/
Other
6.61k stars 2.13k forks source link

Restore autodocs cut-lines with empty what-hints #13013

Closed jdknight closed 1 month ago

jdknight commented 1 month ago

Feature or Bugfix

Purpose

During typecheck improvements, a change accidentally removed the ability for autodoc's cut_lines call to run when no what-hints are provided. The what argument may be empty and an empty scenario should not stop the cut call from processing lines.

Example

An example documentation set configures cut_lines which has a rendering that excludes the leading line of the docstrings. However, a render (at the time of writing) using Sphinx 8.1.2 show docstrings not being cut.

Relates

AA-Turner commented 1 month ago

Sphinx 8.1.3 has been released.

A