859fc4b8734a487ed52220e5e31dc0ee8962ea3a
steve
  Mon Nov 26 14:33:41 2012 -0800
Moved line to delete error file outside of if-statement - otherwise, the error file only gets deleted if there is an error; also added a line to ignore '403 from http://hgwbeta.cse.ucsc.edu/cgi-bin/' as a valid error
diff --git src/utils/qa/checkTrackUiLinks.csh src/utils/qa/checkTrackUiLinks.csh
index 37791f4..d0a9d27 100755
--- src/utils/qa/checkTrackUiLinks.csh
+++ src/utils/qa/checkTrackUiLinks.csh
@@ -82,54 +82,56 @@
 endif
 
 # process "all" choice
 if ("all" == $tableinput) then
   set tables=`getField.csh $db trackDb tableName $machine \
      | grep -v tableName`
   set target="$baseUrl/cgi-bin/hgGateway?hgsid=$hgsid&db=$db"
   # check description page if doing all of an assembly
   htmlCheck checkLinks "$target" >& error
   if ( `wc -w error | awk '{print $1}'` != 0 ) then
     echo
     echo "description.html page:"
     echo "======================"
     cat error
     @ errorCount = $errorCount + 1
-    rm -f error
   endif
+  rm -f error
 endif
 
 foreach table ($tables)
   # check to see if the table exists on the machine
   getField.csh $db trackDb tableName $machine | grep -w $table > /dev/null
   if ( $status ) then
     echo "no such track"
     continue
   endif
   set target="$baseUrl/cgi-bin/hgTrackUi?hgsid=$hgsid&db=$db&g=$table"
   htmlCheck checkLinks "$target" >& error
   # slow it down if hitting the RR
   if ( "true" == $rr ) then
     sleep 2
   endif
   if ( `wc -w error | awk '{print $1}'` != 0 ) then
+    if ( `cat error` != "403 from http://hgwbeta.cse.ucsc.edu/cgi-bin/" ) then
     echo
     echo $table
     echo "============="
     cat error
     @ errorCount = $errorCount + 1
-    rm -f error
   endif
+  endif
+  rm -f error
 end
 echo
 echo "Summary"
 echo "======="
 if ( $errorCount > 0) then
   if ( $errorCount == 1) then
     echo $errorCount "error found"
   else
     echo $errorCount "errors found"
   endif
 else
   echo "No errors found!"
 endif
 echo
