Changeset 37487
- Timestamp:
- Oct 13, 2014, 2:58:06 PM (12 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
tags/ipp-pv3-20140717/ippScripts/scripts/sc_remote_poll.pl
r37322 r37487 164 164 while (my $line = <STATFILE>) { 165 165 chomp $line; 166 unless ($line =~ /dbinfo/) { next; }166 # unless ($line =~ /dbinfo/) { next; } 167 167 168 168 my @words = split (" ", $line); 169 169 170 my ($stage_id, $class_id) = get_stage_id_from_dbinfo ($words[0]); 171 print STDERR "stage_id : $stage_id, class_id: $class_id\n"; 170 my ($stage_id, $class_id, $component) = get_stage_id_from_filename ($words[0]); 171 unless(defined($stage_id)) { 172 print STDERR "Unable to convert file: $words[0]\n"; 173 next; 174 } 175 # print STDERR "stage_id : $stage_id, class_id: $class_id, \n"; 172 176 173 177 if ($words[1] eq "PASS") { 174 push @dbinfo_files, $words[0]; 178 if ($line =~ /dbinfo/) { 179 push @dbinfo_files, $words[0]; 180 } 175 181 $stage_pass{$stage_id} = 1; 176 182 $Npass ++; … … 189 195 if (1) { 190 196 foreach my $file (@dbinfo_files) { 197 my ($stage_id, $class_id) = get_stage_id_from_dbinfo ($file); 198 if (defined($stage_part{$stage_id})|| 199 defined($stage_fail{$stage_id})) { 200 print STDERR "Skipping $file as it is not complete: " . $stage_part{$stage_id} . " " . $stage_fail{$stage_id} . "\n"; 201 next; 202 203 } 191 204 open(DBF,"$file") || warn "Missing file $file\n"; 192 205 my $cmd = <DBF>; … … 465 478 } 466 479 480 sub get_stage_id_from_filename { 481 my $file = shift; 482 my $stage = shift; 483 my $stage_id = -1; 484 my $class_id = ''; 485 486 if ($stage eq 'chip') { 487 ($stage_id, $class_id, $component) = $file =~ /ch\.(\d*).(XY\d\d).([\w\.]+)$/; 488 } 489 elsif ($stage eq 'camera') { 490 if ($file =~ /XY/) { 491 ($stage_id, $class_id, $component) = $file =~ /cm\.(\d*).(XY\d\d)\.([\w\.]+)$/; 492 } 493 else { 494 ($stage_id, $component) = $file =~ /cm\.(\d*)\.([\w\.]+)$/; 495 $class_id = 0; 496 } 497 } 498 elsif ($stage eq 'warp') { 499 ($stage_id, $class_id, $component) = $file =~ /wrp\.(\d*)\.(skycell.\d\d\d\d.\d\d\d).([\w\.]+)$/; 500 } 501 elsif ($stage eq 'stack') { 502 ($stage_id, $component) = $file =~ /stk\.(\d*)\.([\w\.]+)$/; 503 $class_id = 0; 504 } 505 return($stage_id,$class_id,$component); 506 } 507 508 509 467 510 sub fail_component { 468 511 my $remote_id = shift;
Note:
See TracChangeset
for help on using the changeset viewer.
