From 8b39413afc8be15efe21143be8082b8e662a3a49 Mon Sep 17 00:00:00 2001 From: Brecht Van Lommel Date: Thu, 25 May 2023 12:26:56 +0200 Subject: [PATCH] Fix sphinx-build not found in Python venv --- sphinx/sphinx_to_html.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/sphinx/sphinx_to_html.py b/sphinx/sphinx_to_html.py index 95bcad9..8e0f981 100755 --- a/sphinx/sphinx_to_html.py +++ b/sphinx/sphinx_to_html.py @@ -95,7 +95,8 @@ with tempfile.TemporaryDirectory() as tmp_dir: out_dir = work_dir / "out" out_filepath = out_dir / "contents.html" - sphinx_cmd = ["sphinx-build", "-b", "html", work_dir, out_dir] + sphinx_build = script_dir / "venv" / "bin" / "sphinx-build" + sphinx_cmd = [sphinx_build, "-b", "html", work_dir, out_dir] result = subprocess.run(sphinx_cmd, capture_output=True) # Output errors.