- Timestamp:
- Nov 3, 2015, 10:42:21 PM (11 years ago)
- File:
-
- 1 edited
-
trunk/ippToPsps/jython/gpc1db.py (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
trunk/ippToPsps/jython/gpc1db.py
r39015 r39038 535 535 AND stage = 'diff'" 536 536 537 try: 538 rs = self.executeQuery(sql) 539 rs.first() 540 except: 541 self.logger.infoPair("failed sql", sql) 542 self.logger.errorPair("can't query for diff cmf", "dfif_skyfile_id = %d" %diff_skyfile_id) 537 rs = self.executeQuery(sql) 538 539 if not rs.first(): 540 self.logger.errorPair("missing cmf entry diff_skyfile_id:", str(diff_skyfile_id)) 541 # self.logger.errorPair("no diff cmfs found for diff_skyfile_id = %d" %diff_skyfile_id) 543 542 return None 544 print "query worked" 545 try: 546 pathBase = rs.getString(1) 547 except: 548 self.logger.errorPair("no diff cmfs found for diff_skyfile_id = %d" %diff_skyfile_id) 549 return None 550 print pathBase 543 544 pathBase = rs.getString(1) 545 551 546 files = [] 552 547 if pathBase.startswith("neb"): 553 print "open"548 self.logger.debugPair("searching for nebulous files", pathBase) 554 549 f=os.popen("neb-ls -p " + pathBase + ".cmf") 555 550 for i in f.readlines(): 556 print "i",i551 self.logger.debugPair("real file", i.rstrip()) 557 552 files.append(i.rstrip()) 558 print "append"559 # No clue what this is here for, but it breaks things.560 # print i561 553 else: 562 554 files = glob.glob(pathBase + ".cmf") 563 555 564 if len(files) < 1: return None 556 if len(files) < 1: 557 self.logger.errorPair ("no cmf file found matching pathBase", pathBase + ".cmf") 558 return None 559 565 560 fits = Fits(self.logger, self.config, files[0]) 566 561 return fits
Note:
See TracChangeset
for help on using the changeset viewer.
