Fix filenames were not shown on warnings of citations

This commit is contained in:
Takeshi KOMIYA
2016-01-12 12:03:13 +09:00
parent 6dc7ca0234
commit 4c8b575dcc
5 changed files with 5 additions and 3 deletions

View File

@@ -5,6 +5,7 @@ Bugs fixed
----------
* Fix line numbers was not shown on warnings in LaTeX and texinfo builders
* Fix filenames were not shown on warnings of citations
Release 1.3.4 (released Jan 12, 2016)
=====================================

View File

@@ -156,6 +156,7 @@ class CitationReferences(Transform):
refnode = addnodes.pending_xref(cittext, reftype='citation',
reftarget=cittext, refwarn=True,
ids=citnode["ids"])
refnode.source = citnode.source or citnode.parent.source
refnode.line = citnode.line or citnode.parent.line
refnode += nodes.Text('[' + cittext + ']')
citnode.parent.replace(citnode, refnode)

View File

@@ -37,7 +37,7 @@ with "\\?": b?'here: >>>(\\\\|/)xbb<<<'
HTML_WARNINGS = ENV_WARNINGS + """\
%(root)s/images.txt:20: WARNING: no matching candidate for image URI u'foo.\\*'
None:\\d+: WARNING: citation not found: missing
%(root)s/footnote.txt:60: WARNING: citation not found: missing
%(root)s/markup.txt:158: WARNING: unknown option: &option
%(root)s/markup.txt:: WARNING: invalid single index entry u''
%(root)s/markup.txt:: WARNING: invalid pair index entry u''

View File

@@ -25,7 +25,7 @@ from test_build_html import ENV_WARNINGS
LATEX_WARNINGS = ENV_WARNINGS + """\
%(root)s/markup.txt:158: WARNING: unknown option: &option
None:60: WARNING: citation not found: missing
%(root)s/footnote.txt:60: WARNING: citation not found: missing
%(root)s/images.txt:20: WARNING: no matching candidate for image URI u'foo.\\*'
WARNING: invalid pair index entry u''
WARNING: invalid pair index entry u'keyword; '

View File

@@ -24,7 +24,7 @@ from test_build_html import ENV_WARNINGS
TEXINFO_WARNINGS = ENV_WARNINGS + """\
%(root)s/markup.txt:158: WARNING: unknown option: &option
None:60: WARNING: citation not found: missing
%(root)s/footnote.txt:60: WARNING: citation not found: missing
%(root)s/images.txt:20: WARNING: no matching candidate for image URI u'foo.\\*'
%(root)s/images.txt:29: WARNING: no matching candidate for image URI u'svgimg.\\*'
"""