3

I'm using Sphinx 2.2.2 to debug a Sphinx document with a large new source file that contains many cross-references. I get this message:

Warning, treated as error:
C:\Users\...\<filename>.rst::Anonymous hyperlink mismatch: 15 references but 0 targets.
See "backrefs" attribute for IDs.
ERROR: Error while building Main - External manual !

I know roughly what it means: 15 anonymous cross-references point to undefined targets (or perhaps all point to a single undefined target). But how can I find them?

It says I'm supposed to see the "backrefs" attribute for "IDs," which presumably would help me find the problem references. But I don't know what the "backrefs" attribute is, or what it's an attribute of, or how to access it, or what the "IDs" are and what to do with them once I find them.

I've searched the web for references to "backrefs" but didn't find anything that was relevant and comprehensible. Can anyone help?

1 Answers1

3

I had the same issue, it seems my anonymous hyperlinks were not correctly formatted (in your case, 15 are not correctly formatted).

Double check:

  • `foo<http://foo.bar/>`__ : wrong
  • `foo http://foo.bar/>`__ : wrong
  • `foo <http://foo.bar/>`__ : correct

Hope it helps

etiennedm
  • 139