Index: trunk/ippTasks/phase0.pro
===================================================================
--- trunk/ippTasks/phase0.pro	(revision 9081)
+++ trunk/ippTasks/phase0.pro	(revision 9104)
@@ -2,11 +2,11 @@
 ## this file contains the tasks for running the phase 0 stage
 
-## these tasks use the queue Phase0PendingImfiles
-## the Phase0PendingImfiles queue contains:
+## these tasks use the queue Phase0Imfiles
+## the Phase0Imfiles queue contains:
 ## STATE EXP_KEY CLASS CLASS_ID URI-FITS
 ## queue keys are counted from 0
 
-queueinit Phase0PendingImfiles
-queueinit Phase0PendingExposures
+queueinit Phase0Imfiles
+queueinit Phase0Exposures
 if ($?network == 0)
   $network = 1
@@ -17,5 +17,5 @@
 
 # select images ready for phase0 analysis
-# new entries are added to queue Phase0PendingImfiles
+# new entries are added to queue Phase0Imfiles
 # compare the new list with the ones already selected
 task	       phase0.imfile.load
@@ -36,29 +36,29 @@
     # save stdout and stderr
 
-    # compare output with Phase0PendingImfiles queue
+    # compare output with Phase0Imfiles queue
     # only add entries which don't exist in queue
     queuesize stdout -var Nqueue
     for i 0 $Nqueue
       queuepop stdout -var line
-      queuepush Phase0PendingImfiles -uniq -key 1 "NEW $line"
+      queuepush Phase0Imfiles -uniq -key 1 "NEW $line"
     end
 
     # delete existing entries which are DONE
-    queuedrop Phase0PendingImfiles -key 0 DONE
+    queuedrop Phase0Imfiles -key 0 DONE
   end
 
   # locked list
   task.exit    default
-    echo "*** phase0 pending imfiles: failure"
-  end
-
-  # operation times out?
-  task.exit    timeout
-    echo "*** phase0 pending imfiles: timeout"
+    echo "phase0 pending imfiles: failure"
+  end
+
+  # operation times out?
+  task.exit    timeout
+    echo "phase0 pending imfiles: timeout"
   end
 end
 
 # run the phase0imfile script on pending images
-task	       phase0.imfile.process
+task	       phase0.imfile.run
   periods      -poll 0.5
   periods      -exec 1
@@ -66,5 +66,5 @@
 
   task.exec
-    queuesize Phase0PendingImfiles -var N
+    queuesize Phase0Imfiles -var N
     if ($N == 0) break
     if ($network == 0) break
@@ -73,11 +73,11 @@
     # caution with these 'if' statements: syntax errors 
     # will make the task fail without given a good status
-    queuepop Phase0PendingImfiles -var line -key 0 NEW
+    queuepop Phase0Imfiles -var line -key 0 NEW
     if ("$line" == "NULL") break
 
     strpop line state
-    queuepush Phase0PendingImfiles -replace -key 1 "RUN $line"
-
-    ## the Phase0PendingImfiles queue contains (line has popped STATE)
+    queuepush Phase0Imfiles -replace -key 1 "RUN $line"
+
+    ## the Phase0Imfiles queue contains (line has popped STATE)
     ## STATE EXP_KEY CLASS CLASS_ID URI-FITS
     list word -split $line
@@ -103,5 +103,5 @@
   task.exit 0
     # phase0imfile.pl updates DB tables, here we just update the queue
-    queuepush Phase0PendingImfiles -replace -key 1 "DONE $options:0"
+    queuepush Phase0Imfiles -replace -key 1 "DONE $options:0"
   end
 
@@ -109,5 +109,5 @@
   task.exit    default
     echo "failure for phase0imfile.pl: $options:0"
-    queuepush Phase0PendingImfiles -replace -key 1 "FAIL $options:0"
+    queuepush Phase0Imfiles -replace -key 1 "FAIL $options:0"
   end
 
@@ -115,14 +115,14 @@
   task.exit    timeout
     echo "timeout for phase0imfile.pl: $options:0"
-    queuepush Phase0PendingImfiles -replace -key 1 "TIMEOUT $options:0"
-  end
-end
-
-## these tasks use the queue Phase0PendingExposures
-## the Phase0PendingExposures queue contains:
+    queuepush Phase0Imfiles -replace -key 1 "TIMEOUT $options:0"
+  end
+end
+
+## these tasks use the queue Phase0Exposures
+## the Phase0Exposures queue contains:
 ## STATE EXP_KEY CAMERA TELESCOPE TYPE NCLASS
 
 # select images ready for phase0 analysis
-# new entries are added to queue Phase0PendingExposures
+# new entries are added to queue Phase0Exposures
 # compare the new list with the ones already selected
 task	       phase0.exp.load
@@ -141,14 +141,14 @@
     local i Nqueue
 
-    # compare output with Phase0PendingExposures queue
+    # compare output with Phase0Exposures queue
     # only add entries which don't exist in queue
     queuesize stdout -var Nqueue
     for i 0 $Nqueue
       queuepop stdout -var line
-      queuepush Phase0PendingExposures -uniq -key 1 "NEW $line"
+      queuepush Phase0Exposures -uniq -key 1 "NEW $line"
     end
 
     # delete existing entries which are DONE
-    queuedrop Phase0PendingExposures -key 0 DONE
+    queuedrop Phase0Exposures -key 0 DONE
   end
 
@@ -165,5 +165,5 @@
 
 # run the phase0imfile script on pending images
-task	       phase0.exp.process
+task	       phase0.exp.run
   periods      -poll 0.5
   periods      -exec 1.0
@@ -171,5 +171,5 @@
 
   task.exec
-    queuesize Phase0PendingExposures -var N
+    queuesize Phase0Exposures -var N
     if ($N == 0) break
     if ($network == 0) break
@@ -178,11 +178,11 @@
     # caution with these 'if' statements: syntax errors 
     # will make the task fail without given a good status
-    queuepop Phase0PendingExposures -var line -key 0 NEW
+    queuepop Phase0Exposures -var line -key 0 NEW
     if ("$line" == "NULL") break
 
     strpop line state
-    queuepush Phase0PendingExposures -replace -key 1 "RUN $line"
-
-    ## the Phase0PendingExposures queue contains:
+    queuepush Phase0Exposures -replace -key 1 "RUN $line"
+
+    ## the Phase0Exposures queue contains:
     ## STATE EXP_KEY CAMERA TELESCOPE TYPE NCLASS
     list word -split $line
@@ -208,15 +208,15 @@
   task.exit 0
     # phase0exp.pl updates DB tables, here we just update the queue
-    queuepush Phase0PendingExposures -replace -key 1 "DONE $options:0"
+    queuepush Phase0Exposures -replace -key 1 "DONE $options:0"
   end
 
   # default exit status
   task.exit    default
-    queuepush Phase0PendingExposures -replace -key 1 "FAIL $options:0"
-  end
-
-  # operation times out?
-  task.exit    timeout
-    queuepush Phase0PendingExposures -replace -key 1 "TIMEOUT $options:0"
+    queuepush Phase0Exposures -replace -key 1 "FAIL $options:0"
+  end
+
+  # operation times out?
+  task.exit    timeout
+    queuepush Phase0Exposures -replace -key 1 "TIMEOUT $options:0"
   end
 end
