def print_exc(limit=None, file=None):
 if (file is None):
  file = sys.stderr
 try:
  (etype, value, tb) = sys.exc_info()
  print_exception(etype, value, tb, limit, file)
 finally:
  etype = value = tb = None

def print_exc ( limit = None , file = None ) : if ( file is None ) : file = sys . stderr try : ( etype , value , tb ) = sys . exc_info ( ) print_exception ( etype , value , tb , limit , file ) finally : etype = value = tb = None
shorthand for print_exception .