Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
geoms_qa
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
geoms
geoms_qa
Commits
b88e1df2
Commit
b88e1df2
authored
4 years ago
by
Ian Boyd
Browse files
Options
Downloads
Patches
Plain Diff
Replace geoms_qa.pro
parent
da963bd4
No related branches found
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
geoms_qa.pro
+40
-35
40 additions, 35 deletions
geoms_qa.pro
with
40 additions
and
35 deletions
geoms_qa.pro
+
40
−
35
View file @
b88e1df2
...
...
@@ -67,6 +67,9 @@
; 2020-03-11, v2.02 Ian Boyd update due to fix to idlcr8hdf
; 2020-04-27, v2.03 Ian Boyd update due to geoms_vntools update
; 2020-07-09, v2.04 Ian Boyd update due to fix to idlcr8hdf
; 2020-09-30, v2.05 Ian Boyd update due to fix to idlcr8ascii; geoms_tools now returns a QA_error_code
; value of -2 to geoms_qa if idlcr8ascii can't
read
the
input
file
,
to
stop
;
template
and
version
name
checks
;
---------------------------------------------------------------------------------------------------
PRO
geoms_qa
...
...
@@ -74,7 +77,7 @@ PRO geoms_qa
args
=
command_line_args
()
iNrArgs
=
size
(
args
,
/
N_ELEMENTS
)
qaver='version
2.0
4
,
2020
-
0
7
-
09
'
qaver
=
'version 2.0
5
, 2020-0
9-30
'
if
(
iNrArgs
lt
2
)
then
begin
print
...
...
@@ -176,39 +179,41 @@ PRO geoms_qa
Free_Lun
,
lu
endif
;Determine working directory for the version names list file
;First try the template directory, but otherwise use the TAV file directory
if iNrArgs eq 3 then chDirGEOMSvn = FILE_DIRNAME(chFileGEOMSTE, /Mark_Directory) $
else if iNrArgs eq 2 then chDirGEOMSvn = FILE_DIRNAME(chFileTAV, /Mark_Directory) $
else chDirGEOMSvn = '' ;can't
find
directory
holding
the
version
names
list
file
if
(
TC_error_code
eq
0
)
then
begin
TC_error_code
=
geoms_tctools
(
chFileGEOMSTE
,
chFileOrig
,
QA_error_code
)
TC_error_code_hold
=
TC_error_code
*
3
+
4
endif
else
if
(
iNrArgs
eq
3
)
and
(
QA_error_code
ne
3
)
then
begin
logfile
=
STRMID
(
chFileOrig
,
0
,
STRPOS
(
chFileOrig
,
'.'
,
/
REVERSE_SEARCH
))
+
'.log'
OPENW
,
lu
,
logfile
,
/
GET_LUN
,
/
Append
printf
,
lu
,
''
printf
,
lu
,
'ERROR: GEOMS Metadata Template file not found'
Free_Lun
,
lu
QA_error_code
=
3
TC_error_code
=
0
&
TC_error_code_hold
=
0
endif
else
begin
TC_error_code
=
0
&
TC_error_code_hold
=
0
endelse
if
TC_error_code_2
eq
0
then
begin
TC_error_code_2
=
geoms_vntools
(
chDirGEOMSvn
,
chFileOrig
,
QA_error_code
,
TC_error_code
)
;
Note
TC_error_code_2
will
return
the
highest
of
TC_error_code
or
the
Version
Name
error
check
value
if
(
TC_error_code_2
eq
-
1
)
or
(
QA_error_code
eq
3
)
then
begin
;
File
input
error
as
data_version_name
list
file
can
'
t
be
found
and
there
is
a
version
name
in
the
GEOMS
file
TC_error_code
=
0
&
QA_error_code
=
3
endif
else
TC_error_code
=
TC_error_code_2
*
3
+
4
endif
else
TC_error_code
=
TC_error_code_hold
;
total
error
QATC_error_code
=
QA_error_code
+
TC_error_code
exit
,
status
=
QATC_error_code
if
QA_error_code
ne
-
2
then
begin
;
Determine
working
directory
for
the
version
names
list
file
;
First
try
the
template
directory
,
but
otherwise
use
the
TAV
file
directory
if
iNrArgs
eq
3
then
chDirGEOMSvn
=
FILE_DIRNAME
(
chFileGEOMSTE
,
/
Mark_Directory
)
$
else
if
iNrArgs
eq
2
then
chDirGEOMSvn
=
FILE_DIRNAME
(
chFileTAV
,
/
Mark_Directory
)
$
else
chDirGEOMSvn
=
''
;
can't find directory holding the version names list file
if ( TC_error_code eq 0 ) then begin
TC_error_code = geoms_tctools( chFileGEOMSTE, chFileOrig, QA_error_code )
TC_error_code_hold = TC_error_code*3 + 4
endif else if (iNrArgs eq 3) and (QA_error_code ne 3) then begin
logfile=STRMID(chFileOrig,0,STRPOS(chFileOrig,'
.
',/REVERSE_SEARCH))+'
.
log'
OPENW, lu, logfile, /GET_LUN, /Append
printf, lu, ''
printf, lu, '
ERROR
:
GEOMS
Metadata
Template
file
not
found'
Free_Lun, lu
QA_error_code = 3
TC_error_code = 0 & TC_error_code_hold = 0
endif else begin
TC_error_code = 0 & TC_error_code_hold = 0
endelse
if TC_error_code_2 eq 0 then begin
TC_error_code_2 = geoms_vntools( chDirGEOMSvn, chFileOrig, QA_error_code, TC_error_code )
;Note TC_error_code_2 will return the highest of TC_error_code or the Version Name error check value
if (TC_error_code_2 eq -1) or (QA_error_code eq 3) then begin
;File input error as data_version_name list file can't
be
found
and
there
is
a
version
name
in
the
GEOMS
file
TC_error_code
=
0
&
QA_error_code
=
3
endif
else
TC_error_code
=
TC_error_code_2
*
3
+
4
endif
else
TC_error_code
=
TC_error_code_hold
endif
;
total
error
QATC_error_code
=
abs
(
QA_error_code
)
+
TC_error_code
exit
,
status
=
QATC_error_code
END
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment