Skip to content

Commit 7ba3f11

Browse files
committed
Fix --help with python 3.14 and sphinx 8.2.3
The sphinx help strings assert the existence of translations, which are not provided by sphinx-autobuild. Convert the _TranslationProxy objects into English strings.
1 parent cc58cc1 commit 7ba3f11

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

sphinx_autobuild/__main__.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -147,6 +147,10 @@ def _get_sphinx_build_parser():
147147
sphinx_build_parser.description = None
148148
sphinx_build_parser.epilog = None
149149
sphinx_build_parser.prog = "sphinx-autobuild"
150+
for action in sphinx_build_parser._actions:
151+
if hasattr(action, "help"):
152+
# Replace _TranslationProxy objects with strings
153+
action.help = str(action.help)
150154
for action in sphinx_build_parser._actions:
151155
if hasattr(action, "version"):
152156
# Fix the version

0 commit comments

Comments
 (0)