|
12 | 12 | import sys
|
13 | 13 | from os.path import abspath, dirname, join
|
14 | 14 |
|
| 15 | +from sphinx import version_info as sphinx_version |
| 16 | + |
15 | 17 | # Workaround for sphinx-build recursion limit overflow:
|
16 | 18 | # pickle.dump(doctree, f, pickle.HIGHEST_PROTOCOL)
|
17 | 19 | # RuntimeError: maximum recursion depth exceeded while pickling an object
|
@@ -133,13 +135,15 @@ def django_release():
|
133 | 135 | extlinks = {
|
134 | 136 | "bpo": ("https://bugs.python.org/issue?@action=redirect&bpo=%s", "bpo-%s"),
|
135 | 137 | "commit": ("https://github.com/django/django/commit/%s", "%s"),
|
136 |
| - "cve": ("https://nvd.nist.gov/vuln/detail/CVE-%s", "CVE-%s"), |
137 | 138 | "pypi": ("https://pypi.org/project/%s/", "%s"),
|
138 | 139 | # A file or directory. GitHub redirects from blob to tree if needed.
|
139 | 140 | "source": ("https://github.com/django/django/blob/main/%s", "%s"),
|
140 | 141 | "ticket": ("https://code.djangoproject.com/ticket/%s", "#%s"),
|
141 | 142 | }
|
142 | 143 |
|
| 144 | +if sphinx_version < (8, 1): |
| 145 | + extlinks["cve"] = ("https://www.cve.org/CVERecord?id=CVE-%s", "CVE-%s") |
| 146 | + |
143 | 147 | # The language for content autogenerated by Sphinx. Refer to documentation
|
144 | 148 | # for a list of supported languages.
|
145 | 149 | # language = None
|
|
0 commit comments