]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
gh-101845: pyspecific: Fix i18n for availability directive (GH-101846)
authorJean Abou-Samra <jean@abou-samra.fr>
Sun, 12 Feb 2023 14:20:11 +0000 (15:20 +0100)
committerGitHub <noreply@github.com>
Sun, 12 Feb 2023 14:20:11 +0000 (15:20 +0100)
commit6ef6915d3530e844243893f91bf4bd702dfef570
treee97939b46b72b0473d20fd2887df80fa1523b4e7
parentdfc2e065a2e71011017077e549cd2f9bf4944c54
gh-101845: pyspecific: Fix i18n for availability directive (GH-101846)

pyspecific: Fix i18n for availability directive

If the directive has content, the previous code would nest paragraph
nodes from that content inside a general paragraph node, which confuses
Sphinx and leads it to drop the content when translating. Instead, use a
container node for the body.

Also use set_source_info so that any warnings have location info.
Doc/tools/extensions/pyspecific.py