From 240a252d34fff26efad5b3a92e62be4c9af94b70 Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" <41898282+github-actions[bot]@users.noreply.github.com> Date: Sun, 26 May 2024 10:38:25 +0000 Subject: [PATCH] [8.2.x] Add html_baseurl to sphinx conf.py (#12372) Co-authored-by: James Frost --- AUTHORS | 1 + changelog/12363.doc.rst | 1 + doc/en/conf.py | 3 +++ 3 files changed, 5 insertions(+) create mode 100644 changelog/12363.doc.rst diff --git a/AUTHORS b/AUTHORS index 18c60750e30..748b9bae2c8 100644 --- a/AUTHORS +++ b/AUTHORS @@ -192,6 +192,7 @@ Jake VanderPlas Jakob van Santen Jakub Mitoraj James Bourbeau +James Frost Jan Balster Janne Vanhala Jason R. Coombs diff --git a/changelog/12363.doc.rst b/changelog/12363.doc.rst new file mode 100644 index 00000000000..c657281babf --- /dev/null +++ b/changelog/12363.doc.rst @@ -0,0 +1 @@ +The documentation webpages now links to a canonical version to reduce outdated documentation in search engine results. diff --git a/doc/en/conf.py b/doc/en/conf.py index 6438167dc7f..48b40ef9079 100644 --- a/doc/en/conf.py +++ b/doc/en/conf.py @@ -312,6 +312,9 @@ # Output file base name for HTML help builder. htmlhelp_basename = "pytestdoc" +# The base URL which points to the root of the HTML documentation. It is used +# to indicate the location of document using the canonical link relation (#12363). +html_baseurl = "https://docs.pytest.org/en/stable/" # -- Options for LaTeX output --------------------------------------------------