|
From: <mi...@us...> - 2021-06-18 18:55:10
|
Revision: 8771
http://sourceforge.net/p/docutils/code/8771
Author: milde
Date: 2021-06-18 18:55:08 +0000 (Fri, 18 Jun 2021)
Log Message:
-----------
Change default value for the "auto_id_prefix" setting to "%".
Auto-generated IDs use the tag name as prefix.
Set auto_id_prefix_ to "id" if you want unchanged auto-IDs.
Modified Paths:
--------------
trunk/docutils/HISTORY.txt
trunk/docutils/RELEASE-NOTES.txt
trunk/docutils/docs/user/config.txt
trunk/docutils/docutils/frontend.py
trunk/docutils/test/functional/expected/odt_footnotes.odt
trunk/docutils/test/test_nodes.py
trunk/docutils/test/test_parsers/test_recommonmark/test_targets.py
trunk/docutils/test/test_parsers/test_rst/test_character_level_inline_markup.py
trunk/docutils/test/test_parsers/test_rst/test_citations.py
trunk/docutils/test/test_parsers/test_rst/test_definition_lists.py
trunk/docutils/test/test_parsers/test_rst/test_directives/test_include.py
trunk/docutils/test/test_parsers/test_rst/test_directives/test_line_blocks.py
trunk/docutils/test/test_parsers/test_rst/test_directives/test_replace.py
trunk/docutils/test/test_parsers/test_rst/test_directives/test_role.py
trunk/docutils/test/test_parsers/test_rst/test_directives/test_tables.py
trunk/docutils/test/test_parsers/test_rst/test_east_asian_text.py
trunk/docutils/test/test_parsers/test_rst/test_field_lists.py
trunk/docutils/test/test_parsers/test_rst/test_footnotes.py
trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py
trunk/docutils/test/test_parsers/test_rst/test_interpreted.py
trunk/docutils/test/test_parsers/test_rst/test_line_blocks.py
trunk/docutils/test/test_parsers/test_rst/test_section_headers.py
trunk/docutils/test/test_parsers/test_rst/test_substitutions.py
trunk/docutils/test/test_parsers/test_rst/test_targets.py
trunk/docutils/test/test_publisher.py
trunk/docutils/test/test_readers/test_pep/test_inline_markup.py
trunk/docutils/test/test_transforms/test_contents.py
trunk/docutils/test/test_transforms/test_footnotes.py
trunk/docutils/test/test_transforms/test_hyperlinks.py
trunk/docutils/test/test_transforms/test_messages.py
trunk/docutils/test/test_transforms/test_peps.py
trunk/docutils/test/test_transforms/test_sectnum.py
trunk/docutils/test/test_transforms/test_smartquotes.py
trunk/docutils/test/test_transforms/test_substitution_expansion_length_limit.py
trunk/docutils/test/test_transforms/test_substitutions.py
trunk/docutils/test/test_transforms/test_target_notes.py
trunk/docutils/test/test_writers/test_latex2e.py
Modified: trunk/docutils/HISTORY.txt
===================================================================
--- trunk/docutils/HISTORY.txt 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/HISTORY.txt 2021-06-18 18:55:08 UTC (rev 8771)
@@ -14,18 +14,23 @@
Changes Since 0.17.1
====================
+* docutils/frontend.py
+
+ - The default value for the "auto_id_prefix" setting changed to "%":
+ auto-generated IDs use the tag name as prefix.
+
* docutils/nodes.py
- Make meta__ a standard Docutils doctree node. Writers may ignore
"meta" nodes if they are not supported by the output format.
+ __ docs/ref/doctree.html#meta
+
+ - document.make_id(): Keep leading number and hyphen characters
+ from `name` if the id_prefix setting is non-empty.
+
- ``Node.traverse()`` returns an iterator instead of a list.
-
- - document.make_id(): Keep leading number and hyphen characters from `name`
- if the id_prefix setting is non-empty.
- __ docs/ref/doctree.html#meta
-
* docutils/parsers/rst/directives/html.py
- Removed. (Meta directive moved to ``misc.py``.)
Modified: trunk/docutils/RELEASE-NOTES.txt
===================================================================
--- trunk/docutils/RELEASE-NOTES.txt 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/RELEASE-NOTES.txt 2021-06-18 18:55:08 UTC (rev 8771)
@@ -42,11 +42,6 @@
we store the null-escaped text in Text nodes since 0.16 so there is no
additional information in the rawsource.
-* The default value for auto_id_prefix_ will change to "%". This means
- auto-generated IDs will use the tag name as prefix. Set auto_id_prefix_ to
- "id" if you want unchanged auto-IDs or to "%" if you want the new
- feature already in 0.17.
-
* The default HTML writer "html" with frontend ``rst2html.py`` may change
from "html4css1" to "html5".
@@ -60,8 +55,6 @@
* The html_writer_ option of the ``buildhtml.py`` application is
obsoleted by ``--writer`` and will be removed in future.
-.. _id_prefix: docs/user/config.html#id-prefix
-.. _auto_id_prefix: docs/user/config.html#auto-id-prefix
.. _rst2html.py: docs/user/tools.html#rst2html-py
.. _reference name: docs/ref/rst/restructuredtext.html#reference-names
.. _html_writer: docs/user/config.html#html-writer
@@ -77,10 +70,15 @@
characters will not be stripped from a `reference name`_ during
`identifier normalization`_.
- Example: with ``--id-prefix="DU-"``, a section with title "34. May"
- currently gets the identifier key ``DU-may`` and after the change the
- identifier key ``DU-34-may``.
+ Example:
+ with ``--id-prefix="DU-"``, a section with title "34. May"
+ currently gets the identifier key ``DU-may`` and after the
+ change the identifier key ``DU-34-may``.
+ The default value for the auto_id_prefix_ setting changed to "%":
+ use the tag name as prefix for auto-generated IDs.
+ Set auto_id_prefix_ to "id" if you want unchanged auto-IDs.
+
HTML5:
Write footnote brackets and field term colons to HTML, so that they
are present also without CSS and when copying text.
@@ -93,8 +91,6 @@
* Make meta__ a standard Docutils doctree node.
- __ docs/ref/doctree.html#meta
-
* Removed files:
- ``iepngfix.htc`` and ``blank.gif`` (IE 6 workaround for `s5_html`).
@@ -104,8 +100,11 @@
* Various bugfixes and improvements (see HISTORY_).
+__ docs/ref/doctree.html#meta
.. _identifier normalization:
docs/ref/rst/directives.html#identifier-normalization
+.. _id_prefix: docs/user/config.html#id-prefix
+.. _auto_id_prefix: docs/user/config.html#auto-id-prefix
Release 0.17.1 (2021-04-16)
Modified: trunk/docutils/docs/user/config.txt
===================================================================
--- trunk/docutils/docs/user/config.txt 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/docs/user/config.txt 2021-06-18 18:55:08 UTC (rev 8771)
@@ -210,7 +210,7 @@
A trailing "%" is replaced with the tag name (new in Docutils 0.16).
-Default: "id" (`will change to "%" in future`__).
+Default: "%" (changed in 0.18 from "id").
Option: ``--auto-id-prefix`` (hidden, intended mainly for programmatic use).
.. _identifier normalization:
Modified: trunk/docutils/docutils/frontend.py
===================================================================
--- trunk/docutils/docutils/frontend.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/docutils/frontend.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -556,7 +556,7 @@
['--help', '-h'], {'action': 'help'}),
# Typically not useful for non-programmatical use:
(SUPPRESS_HELP, ['--id-prefix'], {'default': ''}),
- (SUPPRESS_HELP, ['--auto-id-prefix'], {'default': 'id'}),
+ (SUPPRESS_HELP, ['--auto-id-prefix'], {'default': '%'}),
# Hidden options, for development use only:
(SUPPRESS_HELP, ['--dump-settings'], {'action': 'store_true'}),
(SUPPRESS_HELP, ['--dump-internals'], {'action': 'store_true'}),
Modified: trunk/docutils/test/functional/expected/odt_footnotes.odt
===================================================================
(Binary files differ)
Modified: trunk/docutils/test/test_nodes.py
===================================================================
--- trunk/docutils/test/test_nodes.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_nodes.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -686,7 +686,8 @@
for element in self.elements:
self.document.set_id(element)
ids = [element['ids'] for element in self.elements]
- self.assertEqual(ids, [['test'], ['id1'], ['id2'], ['id3']])
+ self.assertEqual(ids, [['test'], ['section-1'],
+ ['test-1'], ['footnote-1']])
def test_set_id_custom(self):
# Custom prefixes.
Modified: trunk/docutils/test/test_parsers/test_recommonmark/test_targets.py
===================================================================
--- trunk/docutils/test/test_parsers/test_recommonmark/test_targets.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_recommonmark/test_targets.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -107,10 +107,10 @@
Title
<paragraph>
Paragraph.
- <section dupnames="title" ids="id1">
+ <section dupnames="title" ids="title-1">
<title>
Title
- <system_message backrefs="id1" level="1" line="8" source="test data" type="INFO">
+ <system_message backrefs="title-1" level="1" line="8" source="test data" type="INFO">
<paragraph>
Duplicate implicit target name: "title".
<paragraph>
Modified: trunk/docutils/test/test_parsers/test_rst/test_character_level_inline_markup.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_character_level_inline_markup.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_character_level_inline_markup.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -114,10 +114,10 @@
(escaped; whitespace before end-string).
<paragraph>
However, '
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
args' triggers a warning.
- <system_message backrefs="id2" ids="id1" level="2" line="15" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="15" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
<paragraph>
@@ -124,10 +124,10 @@
Also \n\
<emphasis>
this
- <problematic ids="id4" refid="id3">
+ <problematic ids="problematic-2" refid="system-message-2">
*
.
- <system_message backrefs="id4" ids="id3" level="2" line="17" source="test data" type="WARNING">
+ <system_message backrefs="problematic-2" ids="system-message-2" level="2" line="17" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
@@ -214,10 +214,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
``
literal without closing backquotes
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
"""],
@@ -328,20 +328,20 @@
<document source="test data">
<paragraph>
Adjacent footnote refs are possible with simple-inline-markup:
- <footnote_reference auto="*" ids="id1">
- <footnote_reference auto="1" ids="id2" refname="label">
+ <footnote_reference auto="*" ids="footnote-reference-1">
+ <footnote_reference auto="1" ids="footnote-reference-2" refname="label">
\n\
- <footnote_reference auto="1" ids="id3">
- <footnote_reference ids="id4" refname="2">
+ <footnote_reference auto="1" ids="footnote-reference-3">
+ <footnote_reference ids="footnote-reference-4" refname="2">
2
\n\
- <footnote_reference ids="id5" refname="1">
+ <footnote_reference ids="footnote-reference-5" refname="1">
1
- <footnote_reference auto="*" ids="id6">
- <footnote auto="1" ids="id7">
+ <footnote_reference auto="*" ids="footnote-reference-6">
+ <footnote auto="1" ids="footnote-1">
<paragraph>
test1
- <footnote auto="*" ids="id8">
+ <footnote auto="*" ids="footnote-2">
<paragraph>
test2
"""],
@@ -356,9 +356,9 @@
<document source="test data">
<paragraph>
Adjacent citation refs are possible with simple-inline-markup:
- <citation_reference ids="id1" refname="citation">
+ <citation_reference ids="citation-reference-1" refname="citation">
citation
- <citation_reference ids="id2" refname="cit1">
+ <citation_reference ids="citation-reference-2" refname="cit1">
CIT1
"""],
]
@@ -399,7 +399,7 @@
<paragraph>
<reference refuri="http://example.com/*content">
http://example.com/*content
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
/whatever
<reference refuri="http://example.com/">
@@ -407,7 +407,7 @@
<reference name="rST_for" refname="rst_for">
rST_for
all.html
- <system_message backrefs="id2" ids="id1" level="2" line="8" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="8" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_citations.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_citations.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_citations.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -156,7 +156,7 @@
citation.withdot
<paragraph>
one dot
- <citation ids="id1" names="citation-withdot">
+ <citation ids="citation-withdot-1" names="citation-withdot">
<label>
citation-withdot
<paragraph>
Modified: trunk/docutils/test/test_parsers/test_rst/test_definition_lists.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_definition_lists.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_definition_lists.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -299,75 +299,75 @@
<definition_list_item>
<term>
Term \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`
with \n\
- <problematic ids="id4" refid="id3">
+ <problematic ids="problematic-2" refid="system-message-2">
*
inline \n\
- <problematic ids="id6" refid="id5">
+ <problematic ids="problematic-3" refid="system-message-3">
``
text \n\
- <problematic ids="id8" refid="id7">
+ <problematic ids="problematic-4" refid="system-message-4">
**
errors
<classifier>
classifier \n\
- <problematic ids="id10" refid="id9">
+ <problematic ids="problematic-5" refid="system-message-5">
`
with \n\
- <problematic ids="id12" refid="id11">
+ <problematic ids="problematic-6" refid="system-message-6">
*
errors \n\
- <problematic ids="id14" refid="id13">
+ <problematic ids="problematic-7" refid="system-message-7">
``
too
<definition>
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
- <system_message backrefs="id4" ids="id3" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-2" ids="system-message-2" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
- <system_message backrefs="id6" ids="id5" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-3" ids="system-message-3" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
- <system_message backrefs="id8" ids="id7" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-4" ids="system-message-4" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
- <system_message backrefs="id10" ids="id9" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-5" ids="system-message-5" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
- <system_message backrefs="id12" ids="id11" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-6" ids="system-message-6" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
- <system_message backrefs="id14" ids="id13" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-7" ids="system-message-7" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
<paragraph>
Definition \n\
- <problematic ids="id16" refid="id15">
+ <problematic ids="problematic-8" refid="system-message-8">
`
with \n\
- <problematic ids="id18" refid="id17">
+ <problematic ids="problematic-9" refid="system-message-9">
*
inline \n\
- <problematic ids="id20" refid="id19">
+ <problematic ids="problematic-10" refid="system-message-10">
``
text \n\
- <problematic ids="id22" refid="id21">
+ <problematic ids="problematic-11" refid="system-message-11">
**
markup errors.
- <system_message backrefs="id16" ids="id15" level="2" line="2" source="test data" type="WARNING">
+ <system_message backrefs="problematic-8" ids="system-message-8" level="2" line="2" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
- <system_message backrefs="id18" ids="id17" level="2" line="2" source="test data" type="WARNING">
+ <system_message backrefs="problematic-9" ids="system-message-9" level="2" line="2" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
- <system_message backrefs="id20" ids="id19" level="2" line="2" source="test data" type="WARNING">
+ <system_message backrefs="problematic-10" ids="system-message-10" level="2" line="2" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
- <system_message backrefs="id22" ids="id21" level="2" line="2" source="test data" type="WARNING">
+ <system_message backrefs="problematic-11" ids="system-message-11" level="2" line="2" source="test data" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_directives/test_include.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_directives/test_include.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_directives/test_include.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -307,10 +307,10 @@
<literal>
test_include.py
.
- <section dupnames="inclusion\\ 1" ids="id1">
+ <section dupnames="inclusion\\ 1" ids="inclusion-1-1">
<title>
Inclusion 1
- <system_message backrefs="id1" level="1" line="2" source="%s" type="INFO">
+ <system_message backrefs="inclusion-1-1" level="1" line="2" source="%s" type="INFO">
<paragraph>
Duplicate implicit target name: "inclusion 1".
<paragraph>
@@ -347,10 +347,10 @@
test_include.py
.
<transition>
- <section dupnames="inclusion\\ 1" ids="id1">
+ <section dupnames="inclusion\\ 1" ids="inclusion-1-1">
<title>
Inclusion 1
- <system_message backrefs="id1" level="1" line="2" source="%s" type="INFO">
+ <system_message backrefs="inclusion-1-1" level="1" line="2" source="%s" type="INFO">
<paragraph>
Duplicate implicit target name: "inclusion 1".
<paragraph>
@@ -551,10 +551,10 @@
Block quote ends without a blank line; unexpected unindent.
<paragraph>
error
- <section dupnames="hi" ids="id1">
+ <section dupnames="hi" ids="hi-1">
<title>
hi
- <system_message backrefs="id1" level="1" line="10" source="%(source)s" type="INFO">
+ <system_message backrefs="hi-1" level="1" line="10" source="%(source)s" type="INFO">
<paragraph>
Duplicate implicit target name: "hi".
<system_message level="4" line="12" source="%(source)s" type="SEVERE">
@@ -698,17 +698,17 @@
<paragraph>
$ with inconsistent quoting.
<paragraph>
- <problematic ids="id3" refid="id2">
+ <problematic ids="problematic-1" refid="system-message-1">
:unknown-role:`role`
\n\
and \n\
- <problematic ids="id5" refid="id4">
+ <problematic ids="problematic-2" refid="system-message-2">
*
unbalanced
- <problematic ids="id7" refid="id6">
+ <problematic ids="problematic-3" refid="system-message-3">
`
inline
- <problematic ids="id9" refid="id8">
+ <problematic ids="problematic-4" refid="system-message-4">
**
markup
<system_message level="1" line="63" source="%(source)s" type="INFO">
@@ -715,22 +715,22 @@
<paragraph>
No role entry for "unknown-role" in module "docutils.parsers.rst.languages.en".
Trying "unknown-role" as canonical role name.
- <system_message backrefs="id3" ids="id2" level="3" line="63" source="%(source)s" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="63" source="%(source)s" type="ERROR">
<paragraph>
Unknown interpreted text role "unknown-role".
- <system_message backrefs="id5" ids="id4" level="2" line="63" source="%(source)s" type="WARNING">
+ <system_message backrefs="problematic-2" ids="system-message-2" level="2" line="63" source="%(source)s" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
- <system_message backrefs="id7" ids="id6" level="2" line="63" source="%(source)s" type="WARNING">
+ <system_message backrefs="problematic-3" ids="system-message-3" level="2" line="63" source="%(source)s" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
- <system_message backrefs="id9" ids="id8" level="2" line="63" source="%(source)s" type="WARNING">
+ <system_message backrefs="problematic-4" ids="system-message-4" level="2" line="63" source="%(source)s" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
<paragraph>
- <problematic ids="id11" refid="id10">
+ <problematic ids="problematic-5" refid="system-message-5">
:PEP:`-1`
- <system_message backrefs="id11" ids="id10" level="3" line="68" source="%(source)s" type="ERROR">
+ <system_message backrefs="problematic-5" ids="system-message-5" level="3" line="68" source="%(source)s" type="ERROR">
<paragraph>
PEP number must be a number from 0 to 9999; "-1" is invalid.
<system_message level="1" line="66" source="%(source)s" type="INFO">
Modified: trunk/docutils/test/test_parsers/test_rst/test_directives/test_line_blocks.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_directives/test_line_blocks.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_directives/test_line_blocks.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -67,13 +67,13 @@
<line_block>
<line>
Inline markup \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
may not span
<line_block>
<line>
multiple lines* of a line block.
- <system_message backrefs="id2" ids="id1" level="2" line="3" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="3" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_directives/test_replace.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_directives/test_replace.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_directives/test_replace.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -101,13 +101,13 @@
""",
"""\
<document source="test data">
- <system_message ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
- <system_message ids="id3" level="2" line="1" source="test data" type="WARNING">
+ <system_message ids="system-message-2" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
- <system_message ids="id5" level="2" line="1" source="test data" type="WARNING">
+ <system_message ids="system-message-3" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
<system_message level="3" line="1" source="test data" type="ERROR">
@@ -114,7 +114,7 @@
<paragraph>
Substitution definition contains illegal element <problematic>:
<literal_block xml:space="preserve">
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
<literal_block xml:space="preserve">
.. |name| replace:: *error in **inline ``markup
Modified: trunk/docutils/test/test_parsers/test_rst/test_directives/test_role.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_directives/test_role.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_directives/test_role.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -65,7 +65,7 @@
<document source="test data">
<paragraph>
Must define \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:custom:`interpreted`
before using it.
<system_message level="1" line="1" source="test data" type="INFO">
@@ -72,7 +72,7 @@
<paragraph>
No role entry for "custom" in module "docutils.parsers.rst.languages.en".
Trying "custom" as canonical role name.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
Unknown interpreted text role "custom".
<paragraph>
@@ -263,10 +263,10 @@
<document source="test data">
<paragraph>
Can't use the \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:raw:`role`
directly.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
No format (Writer name) is associated with this role: "raw".
The "raw" role cannot be used directly.
Modified: trunk/docutils/test/test_parsers/test_rst/test_directives/test_tables.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_directives/test_tables.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_directives/test_tables.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -155,7 +155,7 @@
<table>
<title>
title with an \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
error
<tgroup cols="2">
@@ -169,7 +169,7 @@
<entry>
<paragraph>
table
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
@@ -766,7 +766,7 @@
<table>
<title>
error in the \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
title
<tgroup cols="3">
@@ -784,7 +784,7 @@
<entry>
<paragraph>
data
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_east_asian_text.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_east_asian_text.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_east_asian_text.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -39,10 +39,10 @@
""",
u"""\
<document source="test data">
- <section ids="id1" names="タイトル1">
+ <section ids="section-1" names="タイトル1">
<title>
タイトル1
- <section ids="id2" names="タイトル2">
+ <section ids="section-2" names="タイトル2">
<title>
タイトル2
<system_message level="2" line="5" source="test data" type="WARNING">
Modified: trunk/docutils/test/test_parsers/test_rst/test_field_lists.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_field_lists.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_field_lists.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -446,11 +446,11 @@
<field>
<field_name>
Field name with \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
bad inline markup
<field_body>
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
<paragraph>
Modified: trunk/docutils/test/test_parsers/test_rst/test_footnotes.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_footnotes.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_footnotes.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -27,7 +27,7 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
@@ -39,7 +39,7 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
@@ -55,13 +55,13 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
This is a footnote
on multiple lines with more space.
- <footnote ids="id2" names="2">
+ <footnote ids="footnote-2" names="2">
<label>
2
<paragraph>
@@ -75,7 +75,7 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
@@ -89,7 +89,7 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
@@ -101,7 +101,7 @@
""",
"""\
<document source="test data">
- <footnote ids="id1" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<system_message level="2" line="2" source="test data" type="WARNING">
@@ -126,21 +126,21 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference auto="1" ids="id1">
+ <footnote_reference auto="1" ids="footnote-reference-1">
is the first auto-numbered footnote reference.
- <footnote_reference auto="1" ids="id2">
+ <footnote_reference auto="1" ids="footnote-reference-2">
is the second auto-numbered footnote reference.
- <footnote auto="1" ids="id3">
+ <footnote auto="1" ids="footnote-1">
<paragraph>
Auto-numbered footnote 1.
- <footnote auto="1" ids="id4">
+ <footnote auto="1" ids="footnote-2">
<paragraph>
Auto-numbered footnote 2.
- <footnote auto="1" ids="id5">
+ <footnote auto="1" ids="footnote-3">
<paragraph>
Auto-numbered footnote 3.
<paragraph>
- <footnote_reference auto="1" ids="id6">
+ <footnote_reference auto="1" ids="footnote-reference-3">
is the third auto-numbered footnote reference.
"""],
["""\
@@ -160,7 +160,7 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference auto="1" ids="id1" refname="third">
+ <footnote_reference auto="1" ids="footnote-reference-1" refname="third">
is a reference to the third auto-numbered footnote.
<footnote auto="1" ids="first" names="first">
<paragraph>
@@ -172,11 +172,11 @@
<paragraph>
Third auto-numbered footnote.
<paragraph>
- <footnote_reference auto="1" ids="id2" refname="second">
+ <footnote_reference auto="1" ids="footnote-reference-2" refname="second">
is a reference to the second auto-numbered footnote.
- <footnote_reference auto="1" ids="id3" refname="first">
+ <footnote_reference auto="1" ids="footnote-reference-3" refname="first">
is a reference to the first auto-numbered footnote.
- <footnote_reference auto="1" ids="id4" refname="third">
+ <footnote_reference auto="1" ids="footnote-reference-4" refname="third">
is another reference to the third auto-numbered footnote.
<paragraph>
Here are some internal cross-references to the targets generated by
@@ -210,25 +210,25 @@
<paragraph>
Mixed anonymous and labelled auto-numbered footnotes:
<paragraph>
- <footnote_reference auto="1" ids="id1" refname="four">
+ <footnote_reference auto="1" ids="footnote-reference-1" refname="four">
should be 4, \n\
- <footnote_reference auto="1" ids="id2">
+ <footnote_reference auto="1" ids="footnote-reference-2">
should be 1,
- <footnote_reference auto="1" ids="id3">
+ <footnote_reference auto="1" ids="footnote-reference-3">
should be 3, \n\
- <footnote_reference auto="1" ids="id4">
+ <footnote_reference auto="1" ids="footnote-reference-4">
is one too many,
- <footnote_reference auto="1" ids="id5" refname="two">
+ <footnote_reference auto="1" ids="footnote-reference-5" refname="two">
should be 2, and \n\
- <footnote_reference auto="1" ids="id6" refname="six">
+ <footnote_reference auto="1" ids="footnote-reference-6" refname="six">
doesn't exist.
- <footnote auto="1" ids="id7">
+ <footnote auto="1" ids="footnote-1">
<paragraph>
Auto-numbered footnote 1.
<footnote auto="1" ids="two" names="two">
<paragraph>
Auto-numbered footnote 2.
- <footnote auto="1" ids="id8">
+ <footnote auto="1" ids="footnote-2">
<paragraph>
Auto-numbered footnote 3.
<footnote auto="1" ids="four" names="four">
@@ -237,8 +237,8 @@
<footnote auto="1" dupnames="five" ids="five">
<paragraph>
Auto-numbered footnote 5.
- <footnote auto="1" dupnames="five" ids="id9">
- <system_message backrefs="id9" level="2" line="12" source="test data" type="WARNING">
+ <footnote auto="1" dupnames="five" ids="five-1">
+ <system_message backrefs="five-1" level="2" line="12" source="test data" type="WARNING">
<paragraph>
Duplicate explicit target name: "five".
<paragraph>
@@ -267,36 +267,36 @@
Mixed manually-numbered, anonymous auto-numbered,
and labelled auto-numbered footnotes:
<paragraph>
- <footnote_reference auto="1" ids="id1" refname="four">
+ <footnote_reference auto="1" ids="footnote-reference-1" refname="four">
should be 4, \n\
- <footnote_reference auto="1" ids="id2">
+ <footnote_reference auto="1" ids="footnote-reference-2">
should be 2,
- <footnote_reference ids="id3" refname="1">
+ <footnote_reference ids="footnote-reference-3" refname="1">
1
is 1, \n\
- <footnote_reference ids="id4" refname="3">
+ <footnote_reference ids="footnote-reference-4" refname="3">
3
is 3,
- <footnote_reference auto="1" ids="id5">
+ <footnote_reference auto="1" ids="footnote-reference-5">
should be 6, \n\
- <footnote_reference auto="1" ids="id6">
+ <footnote_reference auto="1" ids="footnote-reference-6">
is one too many,
- <footnote_reference auto="1" ids="id7" refname="five">
+ <footnote_reference auto="1" ids="footnote-reference-7" refname="five">
should be 5, and \n\
- <footnote_reference auto="1" ids="id8" refname="six">
+ <footnote_reference auto="1" ids="footnote-reference-8" refname="six">
doesn't exist.
- <footnote ids="id9" names="1">
+ <footnote ids="footnote-1" names="1">
<label>
1
<paragraph>
Manually-numbered footnote 1.
- <footnote auto="1" ids="id10">
+ <footnote auto="1" ids="footnote-2">
<paragraph>
Auto-numbered footnote 2.
<footnote auto="1" ids="four" names="four">
<paragraph>
Auto-numbered footnote 4.
- <footnote ids="id11" names="3">
+ <footnote ids="footnote-3" names="3">
<label>
3
<paragraph>
@@ -304,13 +304,13 @@
<footnote auto="1" dupnames="five" ids="five">
<paragraph>
Auto-numbered footnote 5.
- <footnote auto="1" dupnames="five" ids="id12">
- <system_message backrefs="id12" level="2" line="14" source="test data" type="WARNING">
+ <footnote auto="1" dupnames="five" ids="five-1">
+ <system_message backrefs="five-1" level="2" line="14" source="test data" type="WARNING">
<paragraph>
Duplicate explicit target name: "five".
<paragraph>
Auto-numbered footnote 5 again (duplicate).
- <footnote auto="1" ids="id13">
+ <footnote auto="1" ids="footnote-4">
<paragraph>
Auto-numbered footnote 6.
"""],
@@ -322,7 +322,7 @@
""",
"""\
<document source="test data">
- <footnote auto="*" ids="id1">
+ <footnote auto="*" ids="footnote-1">
<paragraph>
This is an auto-symbol footnote.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_inline_markup.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -72,10 +72,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
emphasis without closing asterisk
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
"""],
@@ -146,10 +146,10 @@
(escaped, whitespace before end-string).
<paragraph>
However, '
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
*
args' will trigger a warning and may be problematic.
- <system_message backrefs="id2" ids="id1" level="2" line="13" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="13" source="test data" type="WARNING">
<paragraph>
Inline emphasis start-string without end-string.
<paragraph>
@@ -360,10 +360,10 @@
) but not (**) or '(** ' or x**2 or **kwargs or **
<paragraph>
(however, '
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
**
kwargs' will trigger a warning and may be problematic)
- <system_message backrefs="id2" ids="id1" level="2" line="4" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="4" source="test data" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
"""],
@@ -389,10 +389,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
**
strong without closing asterisks
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline strong start-string without end-string.
"""],
@@ -514,11 +514,11 @@
but not "``" or ``
<paragraph>
(however, \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
``
standalone TeX quotes'' will trigger a warning
and may be problematic)
- <system_message backrefs="id2" ids="id1" level="2" line="4" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="4" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
"""],
@@ -539,10 +539,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
``
literal without closing backquotes
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline literal start-string without end-string.
"""],
@@ -909,9 +909,9 @@
<paragraph>
Invalid phrase reference:
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:role:`phrase reference`_
- <system_message backrefs="id2" ids="id1" level="2" line="3" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="3" source="test data" type="WARNING">
<paragraph>
Mismatch: both interpreted text role prefix and reference suffix.
"""],
@@ -925,9 +925,9 @@
<paragraph>
Invalid phrase reference:
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`phrase reference`:role:_
- <system_message backrefs="id2" ids="id1" level="2" line="3" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="3" source="test data" type="WARNING">
<paragraph>
Mismatch: both interpreted text role suffix and reference suffix.
"""],
@@ -937,13 +937,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`
phrase \n\
<reference name="reference" refname="reference">
reference
without closing backquote
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
"""],
@@ -953,13 +953,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`
anonymous phrase \n\
<reference anonymous="1" name="reference">
reference
without closing backquote
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
"""],
@@ -1336,10 +1336,10 @@
But this isn't a _target; targets require backquotes.
<paragraph>
And \n\
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
_`
this`_ is just plain confusing.
- <system_message backrefs="id2" ids="id1" level="2" line="3" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="3" source="test data" type="WARNING">
<paragraph>
Inline target start-string without end-string.
"""],
@@ -1349,10 +1349,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
_`
inline target without closing backquote
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline target start-string without end-string.
"""],
@@ -1365,7 +1365,7 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference ids="id1" refname="1">
+ <footnote_reference ids="footnote-reference-1" refname="1">
1
"""],
["""\
@@ -1374,7 +1374,7 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference auto="1" ids="id1">
+ <footnote_reference auto="1" ids="footnote-reference-1">
"""],
["""\
[#label]_
@@ -1382,7 +1382,7 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference auto="1" ids="id1" refname="label">
+ <footnote_reference auto="1" ids="footnote-reference-1" refname="label">
"""],
["""\
[*]_
@@ -1390,7 +1390,7 @@
"""\
<document source="test data">
<paragraph>
- <footnote_reference auto="*" ids="id1">
+ <footnote_reference auto="*" ids="footnote-reference-1">
"""],
["""\
Adjacent footnote refs are not possible: [*]_[#label]_ [#]_[2]_ [1]_[*]_
@@ -1409,7 +1409,7 @@
"""\
<document source="test data">
<paragraph>
- <citation_reference ids="id1" refname="citation">
+ <citation_reference ids="citation-reference-1" refname="citation">
citation
"""],
["""\
@@ -1418,16 +1418,16 @@
"""\
<document source="test data">
<paragraph>
- <citation_reference ids="id1" refname="citation">
+ <citation_reference ids="citation-reference-1" refname="citation">
citation
and \n\
- <citation_reference ids="id2" refname="cit-ation">
+ <citation_reference ids="citation-reference-2" refname="cit-ation">
cit-ation
and \n\
- <citation_reference ids="id3" refname="cit.ation">
+ <citation_reference ids="citation-reference-3" refname="cit.ation">
cit.ation
and \n\
- <citation_reference ids="id4" refname="cit1">
+ <citation_reference ids="citation-reference-4" refname="cit1">
CIT1
but not [CIT 1]_
"""],
@@ -1491,10 +1491,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
|
substitution reference without closing verbar
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline substitution_reference start-string without end-string.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_interpreted.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_interpreted.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_interpreted.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -105,10 +105,10 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`
interpreted without closing backquote
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
"""],
@@ -164,10 +164,10 @@
<document source="test data">
<paragraph>
:title:
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`
` (trailing unquoted space)
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Inline interpreted text or phrase reference start-string without end-string.
"""],
@@ -311,9 +311,9 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:PEP:`-1`
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
PEP number must be a number from 0 to 9999; "-1" is invalid.
"""],
@@ -332,9 +332,9 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:RFC:`0`
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
RFC number must be a number greater than or equal to 1; "0" is invalid.
"""],
@@ -356,13 +356,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:role:`interpreted`
<system_message level="1" line="1" source="test data" type="INFO">
<paragraph>
No role entry for "role" in module "docutils.parsers.rst.languages.en".
Trying "role" as canonical role name.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
Unknown interpreted text role "role".
"""],
@@ -372,13 +372,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
`interpreted`:role:
<system_message level="1" line="1" source="test data" type="INFO">
<paragraph>
No role entry for "role" in module "docutils.parsers.rst.languages.en".
Trying "role" as canonical role name.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
Unknown interpreted text role "role".
"""],
@@ -388,9 +388,9 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:role:`interpreted`:role:
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" source="test data" type="WARNING">
<paragraph>
Multiple roles in interpreted text (both prefix and suffix present; only one allowed).
"""],
@@ -400,13 +400,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:very.long-role_name:`interpreted`
<system_message level="1" line="1" source="test data" type="INFO">
<paragraph>
No role entry for "very.long-role_name" in module "docutils.parsers.rst.languages.en".
Trying "very.long-role_name" as canonical role name.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
Unknown interpreted text role "very.long-role_name".
"""],
@@ -416,13 +416,13 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
:restructuredtext-unimplemented-role:`interpreted`
<system_message level="1" line="1" source="test data" type="INFO">
<paragraph>
No role entry for "restructuredtext-unimplemented-role" in module "docutils.parsers.rst.languages.en".
Trying "restructuredtext-unimplemented-role" as canonical role name.
- <system_message backrefs="id2" ids="id1" level="3" line="1" source="test data" type="ERROR">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="3" line="1" source="test data" type="ERROR">
<paragraph>
Interpreted text role "restructuredtext-unimplemented-role" not implemented.
"""],
Modified: trunk/docutils/test/test_parsers/test_rst/test_line_blocks.py
===================================================================
--- trunk/docutils/test/test_parsers/test_rst/test_line_blocks.py 2021-06-18 18:54:14 UTC (rev 8770)
+++ trunk/docutils/test/test_parsers/test_rst/test_line_blocks.py 2021-06-18 18:55:08 UTC (rev 8771)
@@ -248,16 +248,16 @@
"""\
<document source="test data">
<paragraph>
- <problematic ids="id2" refid="id1">
+ <problematic ids="problematic-1" refid="system-message-1">
|
This is not
- <problematic ids="id4" refid="id3">
+ <problematic ids="problematic-2" refid="system-message-2">
|
a line block
- <system_message backrefs="id2" ids="id1" level="2" line="1" source="test data" type="WARNING">
+ <system_message backrefs="problematic-1" ids="system-message-1" level="2" line="1" so...
[truncated message content] |