IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Mar 11, 2011, 5:36:31 PM (15 years ago)
Author:
bills
Message:

handle case where diffskycell->{data_state} is update, but the diffRun.state or diffRun.label do not have the right values

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/pstamp/scripts/pstamp_checkdependent.pl

    r30851 r30879  
    546546    }
    547547
    548     if ($skycell->{data_state} ne 'update') {
     548    if (($skycell->{data_state} ne 'update') or ($skycell->{state} ne 'update')) {
    549549        my $command = "$difftool -setskyfiletoupdate -diff_id $diff_id -skycell_id $skycell_id";
    550550        $command .= " -set_label $rlabel" if $rlabel;
     551
     552        if (!$no_update) {
     553            my ( $success, $error_code, $full_buf, $stdout_buf, $stderr_buf ) =
     554                        run(command => $command, verbose => $verbose);
     555            unless ($success) {
     556                my_die("failed to queue ${stage}Run $stage_id $component for update", $PS_EXIT_UNKNOWN_ERROR);
     557            }
     558        } else {
     559            print "skipping $command\n";
     560        }
     561    } elsif (defined $rlabel and ($skycell->{label} ne $rlabel)) {
     562        # change the label to match this dependent's rlabel
     563        my $command = "$difftool -updatrun -diff_id $diff_id -set_label $rlabel";
    551564
    552565        if (!$no_update) {
Note: See TracChangeset for help on using the changeset viewer.