IPP Software Navigation Tools IPP Links Communication Pan-STARRS Links

Ignore:
Timestamp:
Oct 1, 2014, 2:50:32 PM (12 years ago)
Author:
heather
Message:

fixes to some bugs

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/ippToPsps/jython/stackbatch.py

    r37433 r37450  
    7373       # we just need one valid filter to get the generic metadata
    7474       validFilter = 'none'
    75 
     75       validFilterCount = 0
    7676       # get a list of stackIDs, identify the CMFs, read the headers:
    7777       for filter in self.filters:
     
    8181           stackID = gpc1Db.getStackIDFromSkyIDAndFilter(skychunk.dvoLabel, skyID, filterName)
    8282           self.stackIDs[filter] = stackID
    83 
     83           if (stackID > 0):
     84               validFilterCount=validFilterCount + 1
    8485           if (stackID <= 0):
    8586               continue
     
    115116           self.logger.errorPair("can't find any valid stacks...?? ","??")
    116117           raise
     118       # did we find any valid stacks?
     119       if validFilterCount == 0:
     120           self.logger.errorPair("can't find any valid stacks...?? ","??")
     121           raise
     122       else:
     123           self.logger.infoPair("number of filters found:",validFilterCount)
    117124   
    118125       validStackID = self.stackIDs[validFilter]
Note: See TracChangeset for help on using the changeset viewer.