From edf720f4127f1e07b8af4a626416477f042847d9 Mon Sep 17 00:00:00 2001 From: Eric Bryant Date: Wed, 16 May 2018 22:17:26 -0400 Subject: [PATCH] HIDDEN_TERMINUS datacheck --- siteupdate/python-teresco/siteupdate.py | 17 ++++++++++++++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/siteupdate/python-teresco/siteupdate.py b/siteupdate/python-teresco/siteupdate.py index 57b30a4c..94fc6dfc 100755 --- a/siteupdate/python-teresco/siteupdate.py +++ b/siteupdate/python-teresco/siteupdate.py @@ -2233,9 +2233,9 @@ def run(self): lines.pop(0) # ignore header line datacheckfps = [] -datacheck_always_error = [ 'DUPLICATE_LABEL', 'LABEL_INVALID_CHAR', - 'LABEL_SLASHES', 'LONG_UNDERSCORE', - 'NONTERMINAL_UNDERSCORE' ] +datacheck_always_error = [ 'DUPLICATE_LABEL', 'HIDDEN_TERMINUS', + 'LABEL_INVALID_CHAR', 'LABEL_SLASHES', + 'LONG_UNDERSCORE', 'NONTERMINAL_UNDERSCORE' ] for line in lines: fields = line.rstrip('\n').split(';') if len(fields) != 6: @@ -2266,6 +2266,17 @@ def run(self): # so the following is simply a placeholder last_visible = None prev_w = None + + # look for hidden termini + if r.point_list[0].is_hidden: + labels = [] + labels.append(r.point_list[0]) + datacheckerrors.append(DatacheckEntry(r,labels,'HIDDEN_TERMINUS')) + if r.point_list[len(r.point_list)-1].is_hidden: + labels = [] + labels.append(r.point_list[len(r.point_list)-1]) + datacheckerrors.append(DatacheckEntry(r,labels,'HIDDEN_TERMINUS')) + for w in r.point_list: # duplicate labels label_list = w.alt_labels.copy()