summaryrefslogtreecommitdiffstats
path: root/parsers/survex.py
diff options
context:
space:
mode:
authorPhilip Sargent <philip.sargent@klebos.com>2022-03-11 16:22:37 +0000
committerPhilip Sargent <philip.sargent@klebos.com>2022-03-11 16:22:37 +0000
commitf99ebf84e9da3a6f65a586977a43af992d6157a6 (patch)
tree20454425a9d9c14826a80976121d2e4b9545c304 /parsers/survex.py
parent8e78dd4a2e8996b8ce41db46fc44874e9df49ddb (diff)
downloadtroggle-f99ebf84e9da3a6f65a586977a43af992d6157a6.tar.gz
troggle-f99ebf84e9da3a6f65a586977a43af992d6157a6.tar.bz2
troggle-f99ebf84e9da3a6f65a586977a43af992d6157a6.zip
running cavern on svx files improved
Diffstat (limited to 'parsers/survex.py')
-rw-r--r--parsers/survex.py8
1 files changed, 7 insertions, 1 deletions
diff --git a/parsers/survex.py b/parsers/survex.py
index 8f3b65d..127bb70 100644
--- a/parsers/survex.py
+++ b/parsers/survex.py
@@ -1221,8 +1221,14 @@ class LoadingSurvex():
self.caverncount += 1
# should also collect all the .err files too and create a DataIssue for each one which
- # - is nonzero in size
+ # - is nonzero in size AND
# - has Error greater than 5% anywhere, or some other more serious error
+
+ errpath = Path(fullpath + ".err")
+ if errpath.is_file():
+ if errpath.stat().st_size == 0:
+ errpath.unlink() # delete empty closure error file
+
svxpath = Path(fullpath + ".svx")
logpath = Path(fullpath + ".log")