diff options
author | Takeshi KOMIYA <i.tkomiya@gmail.com> | 2021-03-14 19:10:52 +0300 |
---|---|---|
committer | GitHub <noreply@github.com> | 2021-03-14 19:10:52 +0300 |
commit | 4915ea6f718f33b4110d17b18c9f57dbafccadd0 (patch) | |
tree | 6db1dc3499615bb6f22996b8a9facc81f22d2866 /sphinx/domains | |
parent | c89bda11d1bb758b557f1cffb593d002ec1e4131 (diff) | |
parent | 5b5730ef4e7a28216f1c402f7e2c955c077c5ac3 (diff) |
Merge pull request #8996 from tk0miya/7119_pending_xref_conditions
Fix #7119: autodoc: Broken doctree was generated by builtin_resolver
Diffstat (limited to 'sphinx/domains')
-rw-r--r-- | sphinx/domains/python.py | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/sphinx/domains/python.py b/sphinx/domains/python.py index f4958a536..cd701ca15 100644 --- a/sphinx/domains/python.py +++ b/sphinx/domains/python.py @@ -1352,6 +1352,10 @@ def builtin_resolver(app: Sphinx, env: BuildEnvironment, return s in typing.__all__ # type: ignore + content = find_pending_xref_condition(node, 'resolved') + if content: + contnode = content.children[0] # type: ignore + if node.get('refdomain') != 'py': return None elif node.get('reftype') in ('class', 'obj') and node.get('reftarget') == 'None': |