Changeset 3104 for coopr.pysp/trunk/coopr/pysp/ef_writer_script.py
- Timestamp:
- Oct 15, 2010 1:08:51 AM (10 years ago)
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
coopr.pysp/trunk/coopr/pysp/ef_writer_script.py
r3102 r3104 286 286 ans = run_ef_writer(options, args) 287 287 else: 288 errmsg = None 288 289 try: 289 290 ans = run_ef_writer(options, args) 290 except ValueError, str: 291 print "VALUE ERROR:" 292 print str 293 except TypeError, str: 294 print "TYPE ERROR:" 295 print str 296 except NameError, str: 297 print "NAME ERROR:" 298 print str 299 except IOError, str: 300 print "IO ERROR:" 301 print str 302 except pyutilib.common.ApplicationError, str: 303 print "APPLICATION ERROR:" 304 print str 305 except RuntimeError, str: 306 print "RUN-TIME ERROR:" 307 print str 308 except: 309 print "Encountered unhandled exception" 291 except ValueError, err: 292 errmsg = 'VALUE ERROR: %s' % err 293 except TypeError, err: 294 errmsg = 'TYPE ERROR: %s' % err 295 except NameError, err: 296 errmsg = 'NAME ERROR: %s' % err 297 except IOError, err: 298 errmsg = 'I/O ERROR: %s' % err 299 except RuntimeError, err: 300 errmsg = 'RUN-TIME ERROR: %s' % err 301 except pyutilib.common.ApplicationError, err: 302 errmsg = 'APPLICATION ERROR: %s' % err 303 except Exception, err: 304 errmsg = 'UNKNOWN ERROR: %s' % err 310 305 traceback.print_exc() 311 sys.exit(0) 306 307 if errmsg is not None: 308 print >>sys.stderr, errmsg 309 sys.exit() 312 310 313 311 gc.enable()
Note: See TracChangeset
for help on using the changeset viewer.