Skip to content

Docs: C annotations extension produces invalid docutils tree #140014

@m-aciek

Description

@m-aciek

The function add_annotations in Doc/tools/extensions/c_annotations.py inserts an emphasis node into a desc_content node. This produces an invalid document tree, since the desc_content node is a docutils Element and is not supposed to have children that are text or inline elements. To fix this, the emphasis node needs to be wrapped in a paragraph node.

[…] the validity of the docutils tree is not checked by docutils or Sphinx.

This prevents to build the documentation to PDF with rinohtype.

Metadata

Metadata

Assignees

Labels

docsDocumentation in the Doc dirtype-bugAn unexpected behavior, bug, or error

Projects

Status

Todo

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions