summaryrefslogtreecommitdiffstats
path: root/Doc
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@python.org>2020-08-12 19:49:22 (GMT)
committerGitHub <noreply@github.com>2020-08-12 19:49:22 (GMT)
commit423e77d6de497931585d1883805a9e3fa4096b0b (patch)
tree83864646e0a96717ce44c7e3e94ee356bbba910d /Doc
parent6e0b7888815e74c67b1fc3c5f60dd4a1aeae127a (diff)
downloadcpython-423e77d6de497931585d1883805a9e3fa4096b0b.zip
cpython-423e77d6de497931585d1883805a9e3fa4096b0b.tar.gz
cpython-423e77d6de497931585d1883805a9e3fa4096b0b.tar.bz2
bpo-40204: Allow pre-Sphinx 3 syntax in the doc (GH-21844)
Enable Sphinx 3.2 "c_allow_pre_v3" option and disable the c_warn_on_allowed_pre_v3 option to make the documentation compatible with Sphinx 2 and Sphinx 3.
Diffstat (limited to 'Doc')
-rw-r--r--Doc/conf.py10
1 files changed, 10 insertions, 0 deletions
diff --git a/Doc/conf.py b/Doc/conf.py
index bfb2a98..079d177 100644
--- a/Doc/conf.py
+++ b/Doc/conf.py
@@ -228,3 +228,13 @@ linkcheck_ignore = [r'https://bugs.python.org/(issue)?\d+',
# Relative filename of the reference count data file.
refcount_file = 'data/refcounts.dat'
+
+# Sphinx 2 and Sphinx 3 compatibility
+# -----------------------------------
+
+# bpo-40204: Allow Sphinx 2 syntax in the C domain
+c_allow_pre_v3 = True
+
+# bpo-40204: Disable warnings on Sphinx 2 syntax of the C domain since the
+# documentation is built with -W (warnings treated as errors).
+c_warn_on_allowed_pre_v3 = False