Skip to content

Commit 53e2850

Browse files
committed
Do not allow intersphinx mappings unless :external: role is used - add this role to rstcheck linting
1 parent 7684a40 commit 53e2850

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

docs/.rstcheck.cfg

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[rstcheck]
22
ignore_directives=automodule,http:get,tabs,tab,prompt,http:patch,http:post,http:put,http:delete
3-
ignore_roles=djangosetting,setting,featureflags,buildpyversions
3+
ignore_roles=djangosetting,setting,featureflags,buildpyversions,external+rtd:doc,external,external+rtd
44
ignore_substitutions=org_brand,com_brand,:smile:,:arrows_counterclockwise:,:heavy_plus_sign:,:tada:,:heart:,:pencil2:
55
# This error needs to be ignored for now
66
# See: https://github.com/myint/rstcheck/issues/19

docs/conf.py

+3
Original file line numberDiff line numberDiff line change
@@ -94,6 +94,9 @@
9494
"rtd": ("https://docs.readthedocs.io/en/stable/", None),
9595
"rtd-dev": ("https://dev.readthedocs.io/en/latest/", None),
9696
}
97+
# Redundant in Sphinx 5.0
98+
# https://www.sphinx-doc.org/en/master/usage/extensions/intersphinx.html#confval-intersphinx_disabled_reftypes
99+
intersphinx_disabled_reftypes = ["std:doc"]
97100
myst_enable_extensions = [
98101
"deflist",
99102
]

0 commit comments

Comments
 (0)