From 9c8ca70b9167d9c225b5f1c68243f0e642df2358 Mon Sep 17 00:00:00 2001 From: Danny Hermes Date: Tue, 1 Oct 2024 09:17:13 -0500 Subject: [PATCH] Update `conf.py` for recent changes to `sphinx_rtd_theme` and RTD. --- docs/conf.py | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/docs/conf.py b/docs/conf.py index 93bbd4af..aeea9b4f 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -26,8 +26,6 @@ import os import sys -import sphinx_rtd_theme - import bezier # ``bezier`` must be installed to build the docs. # If extensions (or modules to document with autodoc) are in another directory, @@ -39,7 +37,7 @@ # If your documentation needs a minimal Sphinx version, state it here. # -needs_sphinx = "6.2.1" +needs_sphinx = "8.0.2" # See: https://github.com/readthedocs/sphinx_rtd_theme/issues/1463 nitpicky = True @@ -153,8 +151,10 @@ # html_theme = "sphinx_rtd_theme" ON_READ_THE_DOCS = os.environ.get("READTHEDOCS") == "True" -if not ON_READ_THE_DOCS: - html_theme_path = [sphinx_rtd_theme.get_html_theme_path()] +if ON_READ_THE_DOCS: + if "html_context" not in globals(): + html_context = {} + html_context["READTHEDOCS"] = True # Theme options are theme-specific and customize the look and feel of a theme # further. For a list of options available for each theme, see the