Skip to content

Commit 4bf7bf8

Browse files
committed
[odmlparser] Update validation warning message
1 parent 7998689 commit 4bf7bf8

File tree

1 file changed

+8
-8
lines changed

1 file changed

+8
-8
lines changed

odml/tools/odmlparser.py

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -70,8 +70,8 @@ def write_file(self, odml_document, filename):
7070

7171
report = validation.report()
7272
if report:
73-
msg += "The saved Document contains formal issues."
74-
msg += " Run 'odml.validation.Validation(doc)' to resolve them.\n%s" % report
73+
msg += "The saved Document contains unresolved issues."
74+
msg += " Run the Documents 'validate' method to access them.\n%s" % report
7575
warnings.warn(msg)
7676

7777
with open(filename, 'w') as file:
@@ -164,8 +164,8 @@ def __init__(self, parser='XML', show_warnings=True):
164164
def _validation_warning(self):
165165
report = Validation(self.doc).report()
166166
if report:
167-
msg = "The loaded Document contains formal issues."
168-
msg += "Run 'odml.validation.Validation(doc)' to resolve them.\n%s" % report
167+
msg = "The loaded Document contains unresolved issues."
168+
msg += " Run the Documents 'validate' method to access them.\n%s" % report
169169
warnings.warn(msg)
170170

171171
def from_file(self, file, doc_format=None):
@@ -244,8 +244,8 @@ def from_file(self, file, doc_format=None):
244244
for doc in self.doc:
245245
report = Validation(doc).report()
246246
if report:
247-
msg = "The loaded Document contains formal issues."
248-
msg += "Run 'odml.validation.Validation(doc)' to resolve them.\n%s" % report
247+
msg = "The loaded Document contains unresolved issues."
248+
msg += " Run the Documents 'validate' method to access them.\n%s" % report
249249
warnings.warn(msg)
250250

251251
return self.doc
@@ -313,8 +313,8 @@ def from_string(self, string, doc_format=None):
313313
for doc in self.doc:
314314
report = Validation(doc).report()
315315
if report:
316-
msg = "The loaded Document contains formal issues."
317-
msg += "Run 'odml.validation.Validation(doc)' to resolve them.\n%s" % report
316+
msg = "The loaded Document contains unresolved issues."
317+
msg += " Run the Documents 'validate' method to access them.\n%s" % report
318318
warnings.warn(msg)
319319

320320
return self.doc

0 commit comments

Comments
 (0)