Index: trunk/ippScripts/scripts/chip_imfile.pl
===================================================================
--- trunk/ippScripts/scripts/chip_imfile.pl	(revision 21202)
+++ trunk/ippScripts/scripts/chip_imfile.pl	(revision 21309)
@@ -53,5 +53,5 @@
     defined $chip_id and
     defined $class_id and
-    ## defined $chip_imfile_id and  XXX until this is added to the scheme, do not require it : 
+    defined $chip_imfile_id and 
     defined $uri and
     defined $camera and
@@ -102,5 +102,4 @@
 $ipprc->outroot_prepare($outroot);
 
-my $image_id = $chip_imfile_id;
 my $source_id = $ipprc->source_id($dbname, $PS_TABLE_ID_CHIP);
 
@@ -133,6 +132,6 @@
         $command .= " -threads $threads" if defined $threads;
         $command .= " -dbname $dbname" if defined $dbname;
-	# $command .= " -image_id $image_id" if defined $image_id;
-	# $command .= " -source_id $source_id" if defined $source_id;
+	$command .= " -image_id $chip_imfile_id" if defined $chip_imfile_id;
+	$command .= " -source_id $source_id" if defined $source_id;
         $command .= " -dumpconfig $configuration";
         $command .= " -tracedest $traceDest -log $logDest";
@@ -143,6 +142,6 @@
         $command .= " -threads $threads" if defined $threads;
         $command .= " -dbname $dbname" if defined $dbname;
-	# $command .= " -image_id $image_id" if defined $image_id;
-	# $command .= " -source_id $source_id" if defined $source_id;
+	$command .= " -image_id $chip_imfile_id" if defined $chip_imfile_id;
+	$command .= " -source_id $source_id" if defined $source_id;
         $command .= " -tracedest $traceDest -log $logDest";
         $command .= " -Db PPIMAGE:PHOTOM FALSE";
Index: trunk/ippScripts/scripts/diff_skycell.pl
===================================================================
--- trunk/ippScripts/scripts/diff_skycell.pl	(revision 21202)
+++ trunk/ippScripts/scripts/diff_skycell.pl	(revision 21309)
@@ -28,8 +28,9 @@
 
 my ($diff_id, $dbname, $threads, $outroot, $reduction, $verbose, $no_update, $no_op, $redirect);
-my $skycell_id;                 # Skycell identifier
+my ($skycell_id, $diff_skyfile_id);
 GetOptions(
     'diff_id=s'         => \$diff_id, # Diff identifier
     'skycell_id=s'      => \$skycell_id, # Diff identifier
+    'diff_skyfile_id=s' => \$diff_skyfile_id, # Diff identifier
     'dbname|d=s'        => \$dbname, # Database name
     'threads=s'         => \$threads,   # Number of threads to use
@@ -48,4 +49,5 @@
           ) unless defined $diff_id
     and defined $skycell_id
+    and defined $diff_skyfile_id
     and defined $outroot;
 
@@ -55,4 +57,6 @@
 my $logDest = "$outroot.log";
 $ipprc->redirect_output($logDest) if $redirect;
+
+my $source_id = $ipprc->source_id($dbname, $PS_TABLE_ID_DIFF);
 
 # Look for programs we need
@@ -212,4 +216,6 @@
     $command .= " -dumpconfig $configuration";
     $command .= " -dbname $dbname" if defined $dbname;
+    $command .= " -image_id $diff_skyfile_id" if defined $diff_skyfile_id;
+    $command .= " -source_id $source_id" if defined $source_id;
 
     my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
Index: trunk/ippScripts/scripts/stack_skycell.pl
===================================================================
--- trunk/ippScripts/scripts/stack_skycell.pl	(revision 21202)
+++ trunk/ippScripts/scripts/stack_skycell.pl	(revision 21309)
@@ -215,6 +215,6 @@
     $command .= " -tracedest $traceDest -log $logDest";
     $command .= " -dbname $dbname" if defined $dbname;
-    # $command .= " -image_id $image_id" if defined $image_id;
-    # $command .= " -source_id $source_id" if defined $source_id;
+    $command .= " -image_id $image_id" if defined $image_id;
+    $command .= " -source_id $source_id" if defined $source_id;
     if ($run_state eq 'new') {
         $command .= " -dumpconfig $configuration";
Index: trunk/ippScripts/scripts/warp_skycell.pl
===================================================================
--- trunk/ippScripts/scripts/warp_skycell.pl	(revision 21202)
+++ trunk/ippScripts/scripts/warp_skycell.pl	(revision 21309)
@@ -51,5 +51,5 @@
 ) unless defined $warp_id
     and defined $skycell_id
-    ### and defined $warp_skyfile_id
+    and defined $warp_skyfile_id
     and defined $tess_dir
     and defined $camera
@@ -64,5 +64,4 @@
 $ipprc->redirect_output($logDest) if $redirect;
 
-my $image_id = $warp_skyfile_id;
 my $source_id = $ipprc->source_id($dbname, $PS_TABLE_ID_WARP);
 
@@ -196,6 +195,6 @@
     $command .= " -threads $threads" if defined $threads;
     $command .= " -dbname $dbname" if defined $dbname;
-    # $command .= " -image_id $image_id" if defined $image_id;
-    # $command .= " -source_id $source_id" if defined $source_id;
+    $command .= " -image_id $warp_skyfile_id" if defined $warp_skyfile_id;
+    $command .= " -source_id $source_id" if defined $source_id;
     if ($run_state eq 'new') {
         $command .= " -dumpconfig $configuration";
