Closes #1159: do not emit duplicate inventory entries for py:module objects.

Also add a workaround on the consumer side in intersphinx, so that links
to projects using old versions of Sphinx generate correct links.
This commit is contained in:
Georg Brandl
2013-09-16 07:54:12 +02:00
parent a58c1332ff
commit ff33545457
2 changed files with 8 additions and 1 deletions

View File

@@ -706,4 +706,5 @@ class PythonDomain(Domain):
for modname, info in self.data['modules'].iteritems():
yield (modname, modname, 'module', info[0], 'module-' + modname, 0)
for refname, (docname, type) in self.data['objects'].iteritems():
yield (refname, refname, type, docname, refname, 1)
if type != 'module': # modules are already handled
yield (refname, refname, type, docname, refname, 1)