summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMichael Williamson <mike@zwobble.org>2026-09-12 10:03:58 +0100
committerMichael Williamson <mike@zwobble.org>2026-09-12 10:03:58 +0100
commit2c398cff79e9035caa5674b5038a87c27353a1c2 (patch)
tree2e58a453e0be11baf2fcddb3e1e5bab0557422c0
parentd9678f1c64103c2062f30dc0dd66a5679ef0cf01 (diff)
Start warning message with capital letter
-rw-r--r--mammoth/docx/body_xml.py4
-rw-r--r--tests/docx/body_xml_tests.py4
2 files changed, 4 insertions, 4 deletions
diff --git a/mammoth/docx/body_xml.py b/mammoth/docx/body_xml.py
index 4abf7f3..7ecf43b 100644
--- a/mammoth/docx/body_xml.py
+++ b/mammoth/docx/body_xml.py
@@ -205,7 +205,7 @@ def _create_reader(numbering, content_types, relationships, styles, docx_file, f
elif fld_char_type == "end":
if len(complex_field_stack) == 0:
return _empty_result_with_message(results.warning(
- "ignoring complex field end character without corresponding start character",
+ "Ignoring complex field end character without corresponding start character",
))
complex_field = complex_field_stack.pop()
@@ -218,7 +218,7 @@ def _create_reader(numbering, content_types, relationships, styles, docx_file, f
elif fld_char_type == "separate":
if len(complex_field_stack) == 0:
return _empty_result_with_message(results.warning(
- "ignoring complex field separator character without corresponding start character",
+ "Ignoring complex field separator character without corresponding start character",
))
complex_field_separate = complex_field_stack.pop()
diff --git a/tests/docx/body_xml_tests.py b/tests/docx/body_xml_tests.py
index b524392..963d3c4 100644
--- a/tests/docx/body_xml_tests.py
+++ b/tests/docx/body_xml_tests.py
@@ -691,7 +691,7 @@ class ComplexFieldTests(object):
assert_that(result.value, is_paragraph(children=is_sequence(
is_empty_run,
)))
- expected_warning = results.warning("ignoring complex field separator character without corresponding start character")
+ expected_warning = results.warning("Ignoring complex field separator character without corresponding start character")
assert_equal([expected_warning], result.messages)
def test_end_character_without_corresponding_start_character_is_ignored(self):
@@ -704,7 +704,7 @@ class ComplexFieldTests(object):
assert_that(result.value, is_paragraph(children=is_sequence(
is_empty_run,
)))
- expected_warning = results.warning("ignoring complex field end character without corresponding start character")
+ expected_warning = results.warning("Ignoring complex field end character without corresponding start character")
assert_equal([expected_warning], result.messages)